Transform documents APIs

circle-exclamation

Authorization

  • Bearer {token} accessible from Authorization - Bearer token or systematically via .

    • The request headers should include a key for Authorization with the value Bearer {token}.

Upload transform document file

Returns: transform object.

POST /{tenant}/api/v4/transforms/{transform_folder}

Add a new transform document to the specified folder based upon the transform filename. The document will be checked against the Validate transform endpoint. If the transform already exists a new version of the transform will be created.

Path parameters

Key
Value

tenant *

Tenant is part of your Log in to Spark URL and also available in the User menu.

transform_folder *

Target folder name.

Request body

Content-Type: multipart/form-data

Key
Value

file

Transform document. The filename must end with _transform.json.

Sample request

Sample response

HTTP 200 OK Content-Type: application/json

Add transform with document content

Returns: transform object.

Add a new transform to the specified folder with the transform name using the content transform document that is included in the request body. The document will be checked against the Validate transform endpoint. If the transform already exists a new version of the transform will be created.

Path parameters

Key
Value

tenant *

Tenant is part of your Log in to Spark URL and also available in the User menu.

transform_folder *

Target folder.

transform *

Target transform document name.

Request body

Content-Type: application/json

Key
Value

transform_content

The entire contents of the Transform documents in a single string. Ensure the content is properly escaped. Content within transform definitions such as input_body_transform or output_body_transform may need to be double escaped, e.g. \" becoming \\\".

Sample request

Sample response

HTTP 200 OK Content-Type: application/json

Validate transform

Returns: transform object.

This API performs the following validations:

  • The transform is valid JSON.

  • transform_type is present and valid.

  • Other checks are specific to the Transform types being used.

Path parameters

Key
Value

tenant *

Tenant is part of your Log in to Spark URL and also available in the User menu.

Request body

Content-Type: application/json

Key
Value

transform_content

Transform documents in a single string. Ensure the content is properly escaped. Content within transform definitions such as input_body_transform or output_body_transform may need to be double escaped, e.g. \" becoming \\\".

Sample request

Sample response

HTTP 200 OK Content-Type: application/json

List transforms

Returns: List of transforms.

Path parameters

Key
Value

tenant *

Tenant is part of your Log in to Spark URL and also available in the User menu.

folder *

Folder associated with the request.

Request body

Content-Type: application/json

Key
Value

page

Page number of the list to get.

pageSize

Number of records per page.

sort

String defining the sort order.

Example: -updated

search

Array of search filter objects. Search filter objects can include: field Name of the field to filter.

value Value of the field to filter.

operator Applies to numeric properties.

Example 1: {"field": "name", "name": "myfoldername" Example 2: {"field": "isstarred", "isstarred", "true"}

Sample request

Sample response

HTTP 200 OK Content-Type: application/json

Get transform document

Returns: transform object.

Path parameters

Key
Value

tenant *

Tenant is part of your Log in to Spark URL and also available in the User menu.

transform_folder *

Folder associated with the request.

transform *

Transform document associated with the request.

Sample request

Sample response

HTTP 200 OK Content-Type: application/json

Delete transform

Returns: transform object.

Path parameters

Key
Value

tenant *

Tenant is part of your Log in to Spark URL and also available in the User menu.

transform_folder *

Folder associated with the request.

transform *

Transform document associated with the request.

Sample request

Sample response

HTTP 200 OK Content-Type: application/json

Last updated