v1
protected
streams

Add a webhook or poll source of a catalog entry to the stream.

Credentials are write-only and held by reference; a webhook source's response carries the public URL to give the provider.

post/v1/workspaces/{workspace}/streams/{stream_id}/sources

Request

  • The document declares no server URL.
  • Auth
    HTTP bearer

Path parameters

stream_idstring uuid required
workspacestring required

Slug of the workspace the request acts in

Request body

configobject

The type's plain settings, e.g. shop_id.

credentialsobject

The type's credential fields, each a value or {secret_id} of a workspace secret. Write-only: never returned.

kind'webhook' | 'poll' | 'platform'
source_typestring required

A slug of GET /streams/source-types.

Response

Successful Response

created_atstring date-time required
event_templatesobject nullable

This source's own kind / key / session_key templates.

idstring uuid required
issuedobject

Credentials generated because they were left out; shown this once only.

kindstring required

webhook or poll

poll_errorstring nullable
polled_atstring date-time nullable
registeredboolean

The provider was pointed at webhook_url (entries with a registration).

source_typestring nullable required

The catalog slug of GET /streams/source-types.

webhook_idstring nullable required
webhook_urlstring nullable required

Public URL the provider posts to; null for a poll source.

Changes

    • breaking

      added the new required request property

    • breaking

      removed the required property from the response with the status

    • breaking

      removed the required property from the response with the status

    • warning

      removed the request property

    • warning

      removed the optional property from the response with the status

    • warning

      removed the optional property from the response with the status

    • warning

      removed the optional property from the response with the status

    • info

      api operation id create_source_v1_streams__stream_id__sources_post removed and replaced with add_source_v1_streams__stream_id__sources_post

    • info

      added the new optional request property

    • info

      added the new optional request property

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the required property to the response with the status

    • info

      endpoint added