The publishing
module provides functionality to work with webhook publishing. The module provides the following methods.
parameters:
- eventId: string
- tokenGetParam: any (optional)
returns: Promise<PublishingEvent>
Gets the event with the provided ID.
parameters:
- eventId: string
- tokenGetParam: any (optional)
returns: Promise<{ data: PublishingMetadataForAsset[] }>
Gets the publishing metadata for the event with the provided ID.
parameters:
- eventId: string
- payload: object
- tokenGetParam: any (optional)
returns: Promise<PublishingMetadataPostResponse>
Adds the publishing metadata for the event with the provided event id. The second parameter payload
contains the publishing metadata to be added. The payload object has the following structure,
{
data: Array<{
assetId: string,
status: "published" | "unpublished" | "synced" | "failed",
statusMessage: string, // optional
locale: string, // optional
publicUrl: string, // optional
publishingDestinationUpdatedAt: string, // optional
}>
}
parameters:
- eventId: string
- assetId: string
- metadataId: string
- tokenGetParam: any (optional)
returns: Promise<PublishingMetadataForAsset>
Gets the publishing metadata of an asset for the event with the provided event ID.