Skip to main content Link Search Menu Expand Document (external link)

Updated Mon Oct 3rd 2022, 21:22 UTC

Create

POST /:account/integrations

Note: This endpoint is still under active development, and may change without warning.

TextUs supports integrating with many partners and third-party services. Each provider has its own set of config parameters.

The most common provider is ‘webhook’, please see the associated documentation for details.

Examples

Create an Integration

Request

POST /my_account/integrations

Body

{
  "@type": "Integration",
  "@context": "/contexts/Integration.jsonld",
  "active": true,
  "provider": "webhook",
  "config": {
    "baseUrl": "https://www.example.com/callback"
  },
  "settings": { }
}
Example
$ curl -i -H Accept:"application/vnd.textus+jsonld" \
    -H Authorization:"Bearer {token}" \
    -X POST /my_account/integrations
    -d '{
  "@type": "Integration",
  "@context": "/contexts/Integration.jsonld",
  "active": true,
  "provider": "webhook",
  "config": {
    "baseUrl": "https://www.example.com/callback"
  },
  "settings": { }
}'

Response

Status

201

Response Type

Integration

Example Body

{
  "@type": "Integration",
  "@context": "/contexts/Integration.jsonld",
  "id": "/integrations/0yX2VrJ",
  "active": true,
  "provider": "webhook",
  "config": {
    "baseUrl": "https://foo.bar.com/zest",
    "webhookSecret": "textus-abcdefgh12345678"
  },
  "settings": {}
}

© 2022 TextUs