---
title: "UpsertGlobalTransform"
method: POST
path: "/v1alpha/global-transforms"
tags: ["GlobalTransformsService"]
---

# UpsertGlobalTransform

`POST /v1alpha/global-transforms`

## Request body

- UpsertGlobalTransformRequest
  - `transform` GlobalTransform — If the specified transform is incompatible with the field data type to which this global transform is connected with, then the end user will get an invalid argument, and the blueprint policy with the global transforms applied won't be returned. Global transforms are identified by an identifier of their [transform]. These are by default loose matching, so that 'Email-PII' is matched when 'email pii' is used.
    - `description` string
    - `tagTransform` GlobalTransformTagTransform
      - `tagContent` string — 'tag_content' is the primary key of TagTransforms.
      - `transforms` FieldTransformTransform[]
        - `aggregation` TransformAggregation
          - `avg` AggregationAvg
            - `castTo` string — Type to cast the original field to before applying the aggregation. By default any field will be cast to decimal.
            - `precision` integer — The precision to use for rounding. When empty, the value is not rounded
          - `max` AggregationMax
          - `min` AggregationMin
          - `partitionBy` DataPolicyField[] — The fields to partition by.
            - `nameParts` string[] — Instead of using "nodes", nesting can be expressed by specifying multiple name parts. A flat table (e.g. csv file) will only contain a single name part for all fields.
            - `required` boolean — Whether the field is required. If not, the field may be null.
            - `tags` string[]
            - `type` string — The data type of the field.
          - `sum` AggregationSum
        - `detokenize` TransformDetokenize
          - `tokenField` DataPolicyField
            - `nameParts` string[] — Instead of using "nodes", nesting can be expressed by specifying multiple name parts. A flat table (e.g. csv file) will only contain a single name part for all fields.
            - `required` boolean — Whether the field is required. If not, the field may be null.
            - `tags` string[]
            - `type` string — The data type of the field.
          - `tokenSourceRef` string — Full reference to the token source, e.g. a fully qualified table name.
          - `valueField` DataPolicyField
            - `nameParts` string[] — Instead of using "nodes", nesting can be expressed by specifying multiple name parts. A flat table (e.g. csv file) will only contain a single name part for all fields.
            - `required` boolean — Whether the field is required. If not, the field may be null.
            - `tags` string[]
            - `type` string — The data type of the field.
        - `fixed` TransformFixed
          - `value` string
        - `hash` TransformHash
          - `seed` string
        - `identity` TransformIdentity
        - `nullify` TransformNullify
        - `numericRounding` TransformNumericRounding
          - `ceil` NumericRoundingCeil
            - `divisor` number, float — The divisor to use when applying integer division. Values < 1 allow for rounding to decimal places.
          - `floor` NumericRoundingFloor
            - `divisor` number, float — The divisor to use when applying integer division. Values < 1 allow for rounding to decimal places.
          - `round` NumericRoundingRound
            - `divisor` number, float — The divisor to use when applying integer division. Advise is to use divisors only when rounding to a multiple of that divisor, with a precision of 0.
            - `precision` integer — The precision to use for rounding. When positive, the value is rounded to the nearest decimal place. When negative, the value is rounded to the nearest power of 10.
        - `principals` DataPolicyPrincipal[] — The principals (e.g. groups) for which this transform will be applied.
          - `group` string — a group of users, different for each platform
          - `permission` string — a permission, currently only supported for Google IAM permissions in BigQuery IAM Check Extension
          - `role` string — a user role, currently only supported for Google IAM roles with BigQuery IAM Check Extension
        - `regexp` TransformRegexp
          - `regexp` string
          - `replacement` string — Use dollar signs to reference capturing groups in the replacement, e.g. "my-replacement-$1-$2". If the replacement is left empty, the regexp match result (full match or first capturing group) is used.
        - `sqlStatement` TransformSqlStatement
          - `statement` string

## Response `200`

OK

- UpsertGlobalTransformResponse
  - `transform` GlobalTransform — If the specified transform is incompatible with the field data type to which this global transform is connected with, then the end user will get an invalid argument, and the blueprint policy with the global transforms applied won't be returned. Global transforms are identified by an identifier of their [transform]. These are by default loose matching, so that 'Email-PII' is matched when 'email pii' is used.
    - `description` string
    - `tagTransform` GlobalTransformTagTransform
      - `tagContent` string — 'tag_content' is the primary key of TagTransforms.
      - `transforms` FieldTransformTransform[]
        - `aggregation` TransformAggregation
          - `avg` AggregationAvg
            - `castTo` string — Type to cast the original field to before applying the aggregation. By default any field will be cast to decimal.
            - `precision` integer — The precision to use for rounding. When empty, the value is not rounded
          - `max` AggregationMax
          - `min` AggregationMin
          - `partitionBy` DataPolicyField[] — The fields to partition by.
            - `nameParts` string[] — Instead of using "nodes", nesting can be expressed by specifying multiple name parts. A flat table (e.g. csv file) will only contain a single name part for all fields.
            - `required` boolean — Whether the field is required. If not, the field may be null.
            - `tags` string[]
            - `type` string — The data type of the field.
          - `sum` AggregationSum
        - `detokenize` TransformDetokenize
          - `tokenField` DataPolicyField
            - `nameParts` string[] — Instead of using "nodes", nesting can be expressed by specifying multiple name parts. A flat table (e.g. csv file) will only contain a single name part for all fields.
            - `required` boolean — Whether the field is required. If not, the field may be null.
            - `tags` string[]
            - `type` string — The data type of the field.
          - `tokenSourceRef` string — Full reference to the token source, e.g. a fully qualified table name.
          - `valueField` DataPolicyField
            - `nameParts` string[] — Instead of using "nodes", nesting can be expressed by specifying multiple name parts. A flat table (e.g. csv file) will only contain a single name part for all fields.
            - `required` boolean — Whether the field is required. If not, the field may be null.
            - `tags` string[]
            - `type` string — The data type of the field.
        - `fixed` TransformFixed
          - `value` string
        - `hash` TransformHash
          - `seed` string
        - `identity` TransformIdentity
        - `nullify` TransformNullify
        - `numericRounding` TransformNumericRounding
          - `ceil` NumericRoundingCeil
            - `divisor` number, float — The divisor to use when applying integer division. Values < 1 allow for rounding to decimal places.
          - `floor` NumericRoundingFloor
            - `divisor` number, float — The divisor to use when applying integer division. Values < 1 allow for rounding to decimal places.
          - `round` NumericRoundingRound
            - `divisor` number, float — The divisor to use when applying integer division. Advise is to use divisors only when rounding to a multiple of that divisor, with a precision of 0.
            - `precision` integer — The precision to use for rounding. When positive, the value is rounded to the nearest decimal place. When negative, the value is rounded to the nearest power of 10.
        - `principals` DataPolicyPrincipal[] — The principals (e.g. groups) for which this transform will be applied.
          - `group` string — a group of users, different for each platform
          - `permission` string — a permission, currently only supported for Google IAM permissions in BigQuery IAM Check Extension
          - `role` string — a user role, currently only supported for Google IAM roles with BigQuery IAM Check Extension
        - `regexp` TransformRegexp
          - `regexp` string
          - `replacement` string — Use dollar signs to reference capturing groups in the replacement, e.g. "my-replacement-$1-$2". If the replacement is left empty, the regexp match result (full match or first capturing group) is used.
        - `sqlStatement` TransformSqlStatement
          - `statement` string

## Other responses

- `default` — Default error response

## Changes

- **2024-01-29** `48511c3bebbb` — 4 info
  - added the new optional request property `transform/tagTransform/transforms/items/principals/items/permission`
  - added the new optional request property `transform/tagTransform/transforms/items/principals/items/role`
  - added the optional property `transform/tagTransform/transforms/items/principals/items/permission` to the response with the `200` status
  - added the optional property `transform/tagTransform/transforms/items/principals/items/role` to the response with the `200` status
- **2023-12-20** `5d53ddeb8184` — 2 info
  - added the new optional request property `transform/tagTransform/transforms/items/numericRounding/allOf[#/components/schemas/Transform_NumericRounding]/round/allOf[#/components/schemas/NumericRounding_Round]/divisor`
  - added the optional property `transform/tagTransform/transforms/items/numericRounding/allOf[#/components/schemas/Transform_NumericRounding]/round/allOf[#/components/schemas/NumericRounding_Round]/divisor` to the response with the `200` status
- **2023-12-15** `0006dd8ef0f4` — 2 info
  - added the new optional request property `transform/tagTransform/transforms/items/aggregation`
  - added the optional property `transform/tagTransform/transforms/items/aggregation` to the response with the `200` status
- **2023-11-29** `8ae5870420f4` — 1 info
  - endpoint added
- **2023-11-17** `04d64891152e` — 1 breaking
  - api path removed without deprecation

[Change history](https://skmtc.dev/getstrm/apis/pace-api/changes/v1alpha/global-transforms/post.md)

---

[API](https://skmtc.dev/getstrm/apis/pace-api.md) · [All operations](https://skmtc.dev/getstrm/apis/pace-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/getstrm/pace-api/revisions/7102a90e7c1e/schema)
