Zum Inhalt springen

ImportWorkflows

POST
/api/v1/t/{tenant}/workflows/imports
curl --request POST \
--url https://example.com/api/v1/t/example/workflows/imports \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: multipart/form-data' \
--form package=@file \
--form applyWhenReady=true
tenant
required
string

Tenant slug

replaceDraft
boolean
Media typemultipart/form-data
object
package
required
string format: binary
applyWhenReady
boolean

OK

Media typeapplication/json
object
id
required
string format: uuid
state
required
Allowed values: NeedsMapping Applied Ready
packageSha256
required
string
commitSha
required
null | string
workflows
required
Array<object>
object
key
required
string
name
required
string
template
required
Allowed values: InvoiceApproval ContractReview MailDistribution HrFileIntake Custom
definitionId
required
null | string format: uuid
new
required
boolean
draftVersion
required
null | integer format: uint32
change
required
Allowed values: New Unchanged Changed
draftChange
required
Allowed values: None Unchanged Changed
workflowDiff
required
One of:
null
draftDiff
required
One of:
null
scripts
required
Array<object>
object
file
required
string
change
required
Allowed values: Added Removed Changed Unchanged
draftChange
required
One of:
null
diff
required
One of:
null
draftDiff
required
One of:
null
checks
required
Array<object>
object
file
required
string
checked
required
boolean
errors
required
integer format: int32
warnings
required
integer format: int32
unmapped
required
Array<object>
object
kind
required
Allowed values: DocumentType Role Member File Tag CostCenter Constant Workflow FileType
key
required
string
number
required
null | string
remembered
required
Array<object>
object
kind
required
Allowed values: DocumentType Role Member File Tag CostCenter Constant Workflow FileType
key
required
string
number
required
null | string
target
required
string format: uuid
expiresAt
required
string format: date-time
Example
{
"state": "NeedsMapping",
"workflows": [
{
"template": "InvoiceApproval",
"change": "New",
"draftChange": "None",
"scripts": [
{
"change": "Added",
"draftChange": "Added"
}
]
}
],
"unmapped": [
{
"kind": "DocumentType"
}
],
"remembered": [
{
"kind": "DocumentType"
}
]
}

Bad Request

Media typeapplication/problem+json
object
type
null | string
title
null | string
status
null | integer format: int32
detail
null | string
instance
null | string
errors
object
key
additional properties
Array<string>
Examplegenerated
{
"type": "example",
"title": "example",
"status": 1,
"detail": "example",
"instance": "example",
"errors": {
"additionalProperty": [
"example"
]
}
}

Forbidden

Media typeapplication/problem+json
object
type
null | string
title
null | string
status
null | integer format: int32
detail
null | string
instance
null | string
Examplegenerated
{
"type": "example",
"title": "example",
"status": 1,
"detail": "example",
"instance": "example"
}

Not Found

Conflict

Media typeapplication/problem+json
object
type
null | string
title
null | string
status
null | integer format: int32
detail
null | string
instance
null | string
Examplegenerated
{
"type": "example",
"title": "example",
"status": 1,
"detail": "example",
"instance": "example"
}

Payload Too Large

Media typeapplication/problem+json
object
type
null | string
title
null | string
status
null | integer format: int32
detail
null | string
instance
null | string
Examplegenerated
{
"type": "example",
"title": "example",
"status": 1,
"detail": "example",
"instance": "example"
}

Unsupported Media Type

Media typeapplication/problem+json
object
type
null | string
title
null | string
status
null | integer format: int32
detail
null | string
instance
null | string
Examplegenerated
{
"type": "example",
"title": "example",
"status": 1,
"detail": "example",
"instance": "example"
}

Too Many Requests

Media typeapplication/problem+json
object
type
null | string
title
null | string
status
null | integer format: int32
detail
null | string
instance
null | string
Examplegenerated
{
"type": "example",
"title": "example",
"status": 1,
"detail": "example",
"instance": "example"
}