POST
/
features
curl --request POST \
  --url https://api.togai.com/features \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "name": "DiscountCredits",
  "schemaAssociations": [
    "event_schema1",
    "event_schema2"
  ]
}'
{
  "id": "feature.1zYnCiM9Bpg.lv25y",
  "name": "DiscountCredits",
  "displayName": "DiscountCredits",
  "schemaAssociations": [
    {
      "schemaName": "event_schema1",
      "attributeName": "distance"
    },
    {
      "schemaName": "event_schema2",
      "attributeName": "time"
    }
  ],
  "createdAt": "2020-01-01T00:00:00Z",
  "updatedAt": "2020-01-01T00:00:00Z"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Payload to create a Feature along the association with event_schemas

Create a Feature stand-alone or associate it with schemas

Response

200
application/json

Response for Create and Get Feature requests

Represents a Feature