Skip to main content
POST
/
transforms
/
{transform_id}
/
clone
Clone Transform
curl --request POST \
  --url https://api.streamkap.com/transforms/{transform_id}/clone \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>"
}
'
import requests

url = "https://api.streamkap.com/transforms/{transform_id}/clone"

payload = { "name": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({name: '<string>'})
};

fetch('https://api.streamkap.com/transforms/{transform_id}/clone', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.streamkap.com/transforms/{transform_id}/clone",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://api.streamkap.com/transforms/{transform_id}/clone"

payload := strings.NewReader("{\n \"name\": \"<string>\"\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://api.streamkap.com/transforms/{transform_id}/clone")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\"\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.streamkap.com/transforms/{transform_id}/clone")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\"\n}"

response = http.request(request)
puts response.read_body
{
  "id": "<string>",
  "name": "<string>",
  "sub_id": "<string>",
  "tenant_id": "<string>",
  "service_id": "<string>",
  "start_time": "<string>",
  "job_name": "<string>",
  "topic_ids": [
    "<string>"
  ],
  "config": {
    "transforms.name": "<string>",
    "transforms.input.topic.pattern": "<string>",
    "transforms.output.topic.pattern": "<string>",
    "transforms.language": "<string>",
    "transforms.input.job.parallelism": 5,
    "transforms.topic.ttl": "<string>",
    "kc.cluster.id": "<string>"
  },
  "implementation": {
    "value_transform": "<string>",
    "key_transform": "<string>",
    "topic_transform": "<string>",
    "common_transform": "<string>",
    "value_schema_transform": "<string>",
    "key_schema_transform": "<string>",
    "unit_test": {
      "test_name": "<string>",
      "input__json": [
        {
          "topic": "<string>",
          "value": {},
          "key": {},
          "timestamp": "2023-11-07T05:31:56Z"
        }
      ],
      "output__json": [
        {
          "topic": "<string>",
          "value": {},
          "key": {},
          "timestamp": "2023-11-07T05:31:56Z"
        }
      ],
      "result__json": [
        {
          "topic": "<string>",
          "value": {},
          "key": {},
          "timestamp": "2023-11-07T05:31:56Z"
        }
      ],
      "is_success": true,
      "html_diff": "<string>",
      "text_diff": "<string>"
    }
  },
  "metrics": {
    "tasks": 123,
    "latency": 123,
    "status": "<string>",
    "duration": 123,
    "start_time": 123,
    "end_time": "<string>",
    "checkpoints": {
      "job_id": "<string>",
      "counts": {},
      "summary": {},
      "latest": {
        "id": 123,
        "status": "<string>",
        "is_savepoint": true,
        "trigger_timestamp": 123,
        "latest_ack_timestamp": 123,
        "state_size": 123,
        "end_to_end_duration": 123,
        "alignment_buffered": 123,
        "num_subtasks": 123,
        "num_acknowledged_subtasks": 123
      },
      "history": [],
      "operator_breakdown": []
    }
  },
  "live_version": "<string>",
  "preview_version": "<string>",
  "version": 1,
  "updated_timestamp": "2023-11-07T05:31:56Z",
  "implementation_updated_timestamp": "2023-11-07T05:31:56Z",
  "description": "<string>",
  "tags": [
    "<string>"
  ],
  "history_created_timestamp": "2023-11-07T05:31:56Z",
  "history_updated_timestamp": "2023-11-07T05:31:56Z"
}
{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

transform_id
string
required

Body

application/json
name
string | null

Response

Successful Response

Basic transform details.

id
string
required
name
string
required
sub_id
string
required
tenant_id
string
required
transform_type
enum<string>
required
Available options:
fan_out,
sql_join,
enrich,
enrich_async,
map_filter,
toast_handling,
un_nesting,
rollup,
topic_router
service_id
string | null
start_time
job_name
string | null
topic_ids
config
TransformConfig · object
implementation
TransformsMapFilterImplementation · object
metrics
TransformMetric · object | null
live_version
string | null
preview_version
string | null
version
integer
default:1
updated_timestamp
string<date-time> | null
implementation_updated_timestamp
string<date-time> | null
description
string | null
tags
string[] | null

List of tag IDs assigned to this transform

history_created_timestamp
string<date-time> | null
history_updated_timestamp
string<date-time> | null