Skip to main content

TAMS API (v1)

Download OpenAPI specification:Download

TamsApiV1Service

jobs

v1/jobs

create diffusion job

Request Body schema: application/json
requestId
required
string

ensure request idempotence, should be unique

required
Array of objects (tams_apiStage)

stages to be executed

notifyUrl
string

Responses

Request samples

Content type
application/json
{
  • "requestId": "string",
  • "stages": [
    ],
  • "notifyUrl": "string"
}

Response samples

Content type
application/json
{
  • "job": {
    }
}

v1/jobs/credits

check job

Request Body schema: application/json
required
Array of objects (tams_apiStage)

stages to be executed

Array
type
required
string (tams_apiStageTypeT)
Default: "DEFAULT"
Enum: "DEFAULT" "INPUT_INITIALIZE" "DIFFUSION" "IMAGE_TO_UPSCALER" "IMAGE_TO_ADETAILER" "IMAGE_TO_INPAINT" "IMAGE_TO_ANIMATE_DIFF"
object (tams_apiInputInitializeInput)
object (tams_apiDiffusionInput)
object (tams_apiImageToUpscalerInput)
object (tams_apiImageToAdetailerInput)
object (tams_apiImageToInpaintInput)

Responses

Request samples

Content type
application/json
{
  • "stages": [
    ]
}

Response samples

Content type
application/json
{
  • "credits": 0
}

v1/jobs/workflow

create workflow job

Request Body schema: application/json
requestId
string
object
runningNotifyUrl
string

Responses

Request samples

Content type
application/json
{
  • "requestId": "string",
  • "params": {
    },
  • "runningNotifyUrl": "string"
}

Response samples

Content type
application/json
{
  • "job": {
    }
}

v1/jobs/workflow/params/check

check workflow request params

Request Body schema: application/json
object
additional property
object (tams_apiWorkflowNode)
classType
string
inputs
object
properties
object

Responses

Request samples

Content type
application/json
{
  • "params": {
    }
}

Response samples

Content type
application/json
{
  • "valid": true,
  • "credits": 0
}

v1/jobs

get job

path Parameters
jobId
required
string <uint64>

Responses

Response samples

Content type
application/json
{
  • "job": {
    }
}

v1/jobs

cancel job

path Parameters
jobId
required
string <uint64>

Responses

Response samples

Content type
application/json
{
  • "jobId": "string"
}

workflow

v1/jobs/workflow/template

create workflow job from template

Request Body schema: application/json
requestId
string
templateId
string <uint64>
object (tams_apiFields)

Responses

Request samples

Content type
application/json
{
  • "requestId": "string",
  • "templateId": "string",
  • "fields": {
    }
}

Response samples

Content type
application/json
{
  • "job": {
    }
}

v1/workflows/template/check

check workflow template params

Request Body schema: application/json
templateId
string <uint64>
object (tams_apiFields)

Responses

Request samples

Content type
application/json
{
  • "templateId": "string",
  • "fields": {
    }
}

Response samples

Content type
application/json
{
  • "valid": true,
  • "credits": 0
}

v1/workflows/{template_id}

get workflow template info

path Parameters
templateId
required
string <uint64>

Responses

Response samples

Content type
application/json
{
  • "templateId": "string",
  • "name": "string",
  • "fields": {
    }
}

models

v1/models/{model_id}

cancel job

path Parameters
modelId
required
string <uint64>

Responses

Response samples

Content type
application/json
{
  • "model": {
    }
}

resource

v1/resource/image

create resource image

Request Body schema: application/json
expireSec
string <int64> (int32 term = 2 [(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = { description: "term of resource, 1-short(keep 7days) 2-long(keep forever)" }];)

Responses

Request samples

Content type
application/json
{
  • "expireSec": "string"
}

Response samples

Content type
application/json
{
  • "resourceId": "string",
  • "putUrl": "string",
  • "headers": { }
}

v1/resource/image/sts

create resource image sts

Request Body schema: application/json
expireSec
string <int64> (int32 term = 2 [(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = { description: "term of resource, 1-short(keep 7days) 2-long(keep forever)" }];)

Responses

Request samples

Content type
application/json
{
  • "expireSec": "string"
}

Response samples

Content type
application/json
{
  • "resourceId": "string",
  • "accessId": "string",
  • "signature": "string",
  • "host": "string",
  • "expire": "string",
  • "callback": "string",
  • "filePath": "string",
  • "policy": "string",
  • "securityToken": "string"
}