创建工作流
创建工作流
OpenAPI
openapi: 3.1.0
info:
title: Activepieces Documentation
version: 0.0.0
servers:
- url: https://cloud.activepieces.com/api
description: Production Server
security: []
externalDocs:
url: https://www.activepieces.com/docs
description: Find more info here
paths:
/v1/flows:
post:
tags:
- flows
description: Create a flow
requestBody:
content:
application/json:
schema:
type: object
properties:
displayName:
type: string
folderId:
type: string
folderName:
type: string
projectId:
type: string
templateId:
type: string
metadata:
type: object
propertyNames:
type: string
additionalProperties: {}
required:
- displayName
- projectId
required: true
responses:
'201':
description: Default Response
content:
application/json:
schema:
type: object
properties:
id:
type: string
created:
type: string
updated:
type: string
projectId:
type: string
externalId:
type: string
ownerId:
anyOf:
- type: string
- type: 'null'
folderId:
anyOf:
- type: string
- type: 'null'
status:
type: string
enum:
- ENABLED
- DISABLED
publishedVersionId:
anyOf:
- type: string
- type: 'null'
metadata:
anyOf:
- type: object
propertyNames:
type: string
additionalProperties: {}
- type: 'null'
operationStatus:
type: string
enum:
- NONE
- DELETING
- ENABLING
- DISABLING
timeSavedPerRun:
anyOf:
- type: number
- type: 'null'
templateId:
anyOf:
- type: string
- type: 'null'
version:
type: object
properties:
id:
type: string
created:
type: string
updated:
type: string
flowId:
type: string
displayName:
type: string
trigger:
anyOf:
- type: object
properties:
name:
type: string
pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
valid:
type: boolean
displayName:
type: string
nextAction: {}
lastUpdatedDate:
type: string
type:
type: string
enum:
- PIECE_TRIGGER
settings:
type: object
properties:
sampleData:
type: object
properties:
sampleDataFileId:
type: string
sampleDataInputFileId:
type: string
lastTestDate:
type: string
additionalProperties: false
propertySettings:
type: object
propertyNames:
type: string
additionalProperties:
type: object
properties:
type:
type: string
enum:
- MANUAL
- DYNAMIC
schema: {}
required:
- type
additionalProperties: false
customLogoUrl:
type: string
pieceName:
type: string
pieceVersion:
type: string
pattern: ^([~^])?[0-9]+\.[0-9]+\.[0-9]+$
triggerName:
type: string
input:
type: object
propertyNames:
type: string
additionalProperties: {}
required:
- propertySettings
- pieceName
- pieceVersion
- input
additionalProperties: false
required:
- name
- valid
- displayName
- lastUpdatedDate
- type
- settings
additionalProperties: false
- type: object
properties:
name:
type: string
pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
valid:
type: boolean
displayName:
type: string
nextAction: {}
lastUpdatedDate:
type: string
type:
type: string
enum:
- EMPTY
settings: {}
required:
- name
- valid
- displayName
- lastUpdatedDate
- type
- settings
additionalProperties: false
updatedBy:
anyOf:
- type: string
- type: 'null'
valid:
type: boolean
schemaVersion:
anyOf:
- type: string
- type: 'null'
agentIds:
type: array
items:
type: string
state:
type: string
enum:
- LOCKED
- DRAFT
connectionIds:
type: array
items:
type: string
backupFiles:
anyOf:
- type: object
propertyNames:
type: string
additionalProperties:
type: string
- type: 'null'
notes:
type: array
items:
type: object
properties:
id:
type: string
content:
type: string
ownerId:
anyOf:
- type: string
- type: 'null'
color:
type: string
enum:
- orange
- red
- green
- blue
- purple
- yellow
position:
type: object
properties:
x:
type: number
'y':
type: number
required:
- x
- 'y'
additionalProperties: false
size:
type: object
properties:
width:
type: number
height:
type: number
required:
- width
- height
additionalProperties: false
createdAt:
type: string
updatedAt:
type: string
required:
- id
- content
- color
- position
- size
- createdAt
- updatedAt
additionalProperties: false
required:
- id
- created
- updated
- flowId
- displayName
- trigger
- valid
- agentIds
- state
- connectionIds
- notes
additionalProperties: false
triggerSource:
type: object
properties:
schedule:
anyOf:
- type: object
properties:
type:
type: string
enum:
- CRON_EXPRESSION
cronExpression:
type: string
timezone:
type: string
required:
- type
- cronExpression
- timezone
additionalProperties: false
- type: 'null'
additionalProperties: false
required:
- id
- created
- updated
- projectId
- externalId
- status
- operationStatus
- version
additionalProperties: false
security:
- apiKey: []
components:
securitySchemes:
apiKey:
type: http
description: Use your api key generated from the admin console
scheme: bearer