Applications
Get App
GET /api/apps/<app_id>/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the application id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 200 OK
Return the App.
Example:
{
"name": "my_app",
"canvas_id": "8101c262-be18-40c7-a85a-78b47dcdf80d"
}
Failed status: 404 NOT_FOUND
Get App Status
GET /api/apps/<app_id>/status/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 200 OK
Name | Type | Description |
---|---|---|
| string | The application status |
Example:
{
"status": "started/stopped/not-deployed"
}
Failed status: 404 NOT_FOUND
Get App MiniApps
Get the list of miniApps used by this application including all of its flows.
Returns a list of miniApp ids by default. More details can be returned with the details
query param.
GET /api/apps/<app_id>/miniapps/?details=&type=
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Query params
Name | Type | Description | Example |
---|---|---|---|
| boolean | if extra details about the miniApps should be included (default is False) | true |
| string | miniApp type used as filter | "Banking", "Numeric", "Intent" |
Successful status: 200 OK
List of miniApps.
Example 1:
/apps/<app_id>/miniapps/
[
"b759a24f-6afa-4bcf-b213-257ee6037175.ia_orc_intent.Banking.MiniApps.orc",
"b759a24f-6afa-4bcf-b213-257ee6037175.ia_orc_announcement_2.Announcement.MiniApps.orc",
"4d5195f9-ce70-488c-bb3c-f67bc567521f.dt_orc_ann_info_yes.Announcement.MiniApps.orc"
]
Example 2:
/apps/<app_id>/miniapps/?detail=true
[
{
"id": "b759a24f-6afa-4bcf-b213-257ee6037175.ia_orc_intent.Banking.MiniApps.orc",
"name": "ia_orc_intent",
"type": "Banking"
},
{
"id": "b759a24f-6afa-4bcf-b213-257ee6037175.ia_orc_announcement_2.Announcement.MiniApps.orc",
"name": "ia_orc_intent",
"type": "Announcement"
}
]
Get App Flows
Get the list of Flows used by this application.
GET /api/apps/<app_id>/flows/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 200 OK
List of Flows.
Example:
[
{
"id": "660f41a1-75e2-4c29-bdde-a90ab529b30d",
"version": "0.0.2",
"component_id": "88ed36b3-4e0c-4b5b-b9be-c733b3c5f21f.orc_export_test_flow.Flows.orc.ktselepakis",
"created_at": "2022-02-17T15:02:01.509054Z",
"updated_at": "2022-04-15T09:31:47.631558Z",
"production_flowapp_id": "88ed36b3-4e0c-4b5b-b9be-c733b3c5f21f.PRD_orc_export_test_flow.Flow.ktselepakis@PRD_orc_export_test_flow.ktselepakis",
"sandbox_flowapp_id": "88ed36b3-4e0c-4b5b-b9be-c733b3c5f21f.SND_orc_export_test_flow.Flow.ktselepakis@SND_orc_export_test_flow.ktselepakis",
"user_id": "88ed36b3-4e0c-4b5b-b9be-c733b3c5f21f",
"group": "ktselepakis",
"name": "orc_export_test_flow",
"input_fields": [
"foo"
],
"output_fields": [
"bar"
],
"canvas": "a8a9791f-205c-4995-bf20-1be2e860dc4a"
}
]
Failed status: 404 NOT_FOUND
Create App
POST /api/apps/
Name | Type | Description | Example |
---|---|---|---|
| string | - | The application name |
Example:
{
"name": "my_app"
}
Successful status: 201 CREATED
The created App.
Example:
{
"name": "my_app",
"canvas_id": "8101c262-be18-40c7-a85a-78b47dcdf80d"
}
Failed status: 404 NOT_FOUND
Failed status: 400 BAD_REQUEST
when the app name contains invalid characters (acceptable app name characters are only alphanumeric [a-Z0-9] and the underscore character '_')
Example:
CODE{ "name": [ "Invalid app name. App name must contain only alphanumeric characters and the underscore character." ] }
Delete App
DELETE /api/apps/<app_id>/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 204 NO_CONTENT
Failed status: 404 NOT_FOUND
Deploy App
This request compiles the Orchestrator App, creates a relative DiaManT App (if there is none), uploads a DiaManT App configuration, makes the deployment and starts the application.
POST /api/apps/<app_id>/deploy/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 200 OK
The deployment results.
Example:
{
"detail": "The application has been deployed and start and running successfully."
}
Failed status: 400 BAD_REQUEST
something went wrong with the app deployment. Usually there was a canvas warning.
Example:
JSON{ "detail": "Your App can not be deployed because it contains problems: Multiple roots found on the graph.", "errors": [ { "canvas_id": "1ebbcc51-19a2-47cb-bba9-0bc6164a94cb", "node_errors": [ { "node_id": "1", "errors": [ { "type": "WARNING", "code": "MULTIPLE_ROOTS_FOUND", "message": "Multiple roots found on the graph.", } ] }, { "node_id": "2", "errors": [ { "type": "WARNING", "code": "MULTIPLE_ROOTS_FOUND", "message": "Multiple roots found on the graph.", } ] } ] } ] }
Get Web Chat Info
Help start a chat simulation with an App by providing useful web chat related info.
GET /api/apps/<app_id>/web_chat/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 200 OK
Return web-chat related info.
Name | Type | Description |
---|---|---|
| string | The URL linked with the chat connector web socket |
| string | The access token for the deployed application |
| string | The access token for the simulator application |
Example:
{
"chat_url": "wss://lab.miniapps.ocp.ai/chat/ws/dialogs",
"deployed_token": "435f6ea2f72df13732c29414a0446a9e11d7fd46412bfe1c3fc1961736d8ff71467623cb64532352",
"live_token": "1c58b47ae31fb9e8a8b89b4e201f821d3ac5983492619fe8f740dd2404010c6134673c6869fe64ae"
}
Get App's Attached Data
Request to get the Application's Attached Data.
GET /api/apps/<app_id>/attached_data/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 200 OK
Return the app's attached data (key/value pairs).
Example:
{
"ad_key_1": "ad_value_1",
"ad_key_2": "ad_value_2",
"ad_key_3": "ad_value_3"
}
Update App's Attached Data
Update Application's Attached Data.
PUT /api/apps/<app_id>/attached_data/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 200 OK
Return the updated app's attached data (key/value pairs).
Example:
{
"ad_key_1": "ad_value_1",
"ad_key_2": "ad_value_2",
"ad_key_3": "ad_value_3"
}
Get App's Fail Sources
Return App's list of Fail Sources, which are available to be used as fail sources for the Error Handlers.
Fail Sources contain a display_name
and a fail_source_path
:
display_name
is more user-friendly and is meant for users to readfail_source_path
is the actual value that needs to be used when setting an ErrorSource for an Error Handler object.
GET /api/apps/<app_id>/fail_sources/
URL params
Name | Type | Description | Example |
---|---|---|---|
app_id | uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 200 OK
Return list of App's fail sources.
Name | Type | Description | Example |
---|---|---|---|
| string | fail source's name to display | "ia_iandronis_intent_1" |
| string | fail source's path | "0e694182-1cec-406d-83ce-46cdf9d56b1c.ia_iandronis_intent_1.Banking.MiniApps.iandronis" |
Example:
[
{
"display_name": "ia_iandronis_intent_1",
"fail_source_path": "0e694182-1cec-406d-83ce-46cdf9d56b1c.ia_iandronis_intent_1.Banking.MiniApps.iandronis"
},
{
"display_name": "ia_iandronis_announcement_1",
"fail_source_path": "0e694182-1cec-406d-83ce-46cdf9d56b1c.ia_iandronis_announcement_1.Announcement.MiniApps.iandronis"
},
{
"display_name": "ia_local_lab_flow_1.ia_iandronis_intent_1",
"fail_source_path": "0e694182-1cec-406d-83ce-46cdf9d56b1c.ia_local_lab_flow_1.Flows.orc.iandronis::0e694182-1cec-406d-83ce-46cdf9d56b1c.ia_iandronis_intent_1.Banking.MiniApps.iandronis"
},
{
"display_name": "ia_local_lab_flow_1.ia_iandronis_announcement_2",
"fail_source_path": "0e694182-1cec-406d-83ce-46cdf9d56b1c.ia_local_lab_flow_1.Flows.orc.iandronis::0e694182-1cec-406d-83ce-46cdf9d56b1c.ia_iandronis_announcement_2.Announcement.MiniApps.iandronis"
}
]
Failed status: 400 BAD_REQUEST
there was a cycle reference inside the app (probably by some flows)
Example:
JSON{ "detail": "Found cycle use of a Flow in the application (use trace: ['test_user_id.my_app.Flows.orc.group', 'test_user_id.my_flow_lvl_1.Flows.orc.group', 'test_user_id.my_flow_lvl_2.Flows.orc.group'] -> test_user_id.my_flow_lvl_1.Flows.orc.group)." }
Get App's Export
This endpoint exports the application and all the related flows in a zip.
GET /api/apps/<app_id>/export/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 200 OK
Return the app's export file.
Failed status: 404 NOT_FOUND
Get Available Voice Biometric Profiles
Get available Voice Biometric Profiles.
GET /api/voice-biometric/profiles/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 200 OK
List of Voice Biometric Profiles.
Example:
[
{
"profile_id": "DEF",
"name": "Default",
"bio_keys": [
{
"id": 1,
"key": "userID",
"display_name": "userID"
},
{
"id": 168,
"key": "Ani",
"display_name": "Ani"
}
]
},
{
"profile_id": "XLh0g6d0",
"name": "test",
"bio_keys": [
{
"id": 276,
"key": "user_id",
"display_name": "user_id"
},
{
"id": 277,
"key": "Ani",
"display_name": "Ani"
}
]
}
]
Get App's Voice Biometric Profile
Get App's Voice Biometric Profile.
GET /api/apps/<app_id>/voice-biometric/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Successful status: 200 OK
The App Biometric Profile.
Example:
{
"profile_id": "DEF",
"field_mappings": [
{
"bio_key": "Ani",
"orc_field": "Ani"
},
{
"bio_key": "userID",
"orc_field": "Dnis"
}
]
}
Update App's Voice Biometric Profile
Update App's Voice Biometric Profile.
PUT /api/apps/<app_id>/voice-biometric/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Request payload
App Voice Biometric Profile variables.
Successful status: 200 OK
The updated App Voice Biometric Profile.
Example:
{
"profile_id": "DEF",
"field_mappings": [
{
"bio_key": "Ani",
"orc_field": "Ani"
},
{
"bio_key": "userID",
"orc_field": "Dnis"
}
]
}
Unset App's Voice Biometric Profile
To remove the connection between VB profile keys and orc fields, send update request with empty profile_id
value.
PUT /api/apps/<app_id>/voice-biometric/
URL params
Name | Type | Description | Example |
---|---|---|---|
| uuid | the app's id | "9b399774-3a0a-40c1-8a1c-4a124170b6f3" |
Request payload
App Voice Biometric Profile variables.
Successful status: 200 OK
The updated App Voice Biometric Profile.
Example:
{
"profile_id": "",
"field_mappings": []
}
Models
Voice Biometric Profile
Name | Type | Description |
---|---|---|
| string | The profile's id |
| string | The profile's name |
| array[dict] | The profile's bio keys |
Example:
{
"profile_id": "DEF",
"name": "Default",
"bio_keys": [
{
"id": 1,
"key": "userID",
"display_name": "userID"
},
{
"id": 168,
"key": "Ani",
"display_name": "Ani"
}
]
}
App Voice Biometric Profile
Name | Type | Description |
---|---|---|
| string | The Voice Biometrics profile's id |
| array[dict] | Mapping of Orchestrator Application field (key) to Voice Biometrics bio_key id (value) |
Example:
{
"profile_id": "DEF",
"field_mappings": [
{
"bio_key": "Ani",
"orc_field": "Ani"
},
{
"bio_key": "userID",
"orc_field": "Dnis"
}
]
}