API Reference
API Reference

Create Service

Create a new service.

POST/api/v1/services/

Authentication

Syllable-API-Keyrequired

Send Syllable-API-Key in the header.

Need a credential? Create or manage an API token in the Syllable Console.

Parameters

This endpoint has no declared parameters.

Request body

application/json

body ServiceCreateRequest required
4 fields
namestringrequired

The name of the service

descriptionstringrequired

The description of the service

auth_typeenum<string> | nulloptional

The type of authentication to use for the service's tools

Allowed values ["basic","bearer","custom_headers","oauth2"]
auth_valuesunspecified | nulloptional

The values to use for the authentication, as a dict. Should contain "username" and "password" keys if auth type is basic, "token" key if auth type is bearer, arbitrary header keys if auth type is custom_headers. or "client_id", "client_secret", and "auth_url" keys if auth type is oauth2. On an update, leave a value for a given key null and the value in the database will not be updated. (If a key is omitted entirely, any existing value for that key will be removed.)

Request example
{
  "name": "string",
  "description": "string",
  "auth_type": "string",
  "auth_values": "string"
}

Responses

200Successful Response

application/json

response ServiceResponse required
9 fields
idintegerrequired

The internal ID of the service

namestringrequired

The name of the service

descriptionstringrequired

The description of the service

auth_typeenum<string> | nulloptional

The type of authentication to use for the service's tools

Allowed values ["basic","bearer","custom_headers","oauth2"]
auth_value_keysstring[] | nulloptional

Auth value keys (values omitted for security)

Item schema
itemsstringrequired
last_updated_commentsstring | nulloptional

Free text providing comment about what was updated

last_updatedstring (date-time)required

The timestamp of the most recent update to the service

last_updated_bystringrequired

The email of the user who last updated the service

toolsstring[]required

Names of tools that belong to the service

Item schema
itemsstringrequired
Response example
{
  "id": 0,
  "name": "string",
  "description": "string",
  "auth_type": "string",
  "auth_value_keys": "string",
  "last_updated_comments": "string",
  "last_updated": "string",
  "last_updated_by": "string",
  "tools": [
    "string"
  ]
}
422Validation Error

application/json

response HTTPValidationError required
1 field
detailValidationError[]optional
Item schema
itemsValidationErrorrequired
3 fields
locstring | integer[]required
Item schema
itemsstring | integerrequired
2 options
Option 1stringrequired
Option 2integerrequired
msgstringrequired
typestringrequired
Response example
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}