Sign inGet started

Macros

GET
/workspaces/{workspaceId}/macros
Retrieve list of macros.
Parametry zapytania
limit
integer
Limits the number of results to return.
pageToken
string
The cursor that keeps track of the current position in the results.
reverse
boolean
Reverses the order in which the results are returned.
sort
string
The field by which to sort macros.
Possible values: createdAt, updatedAt, name, language
q
string
A full-text search parameter that searches for macros by name, response body, and/or tag name.
languages
array
Filter macros by language. Multiple languages are combined with a logical OR.
tagIds
array
Filter macros by tag IDs. Multiple tag IDs are combined with a logical AND.
Treść odpowiedzi
results
array of object
wymagane
Pokaż atrybuty podrzędne
results.id
string
wymagane
results.name
string
wymagane
The user-defined display name of the macro.
results.response
object
Pokaż atrybuty podrzędne
results.response.text
object
wymagane
Pokaż atrybuty podrzędne
results.response.text.actions
array of object
Pokaż atrybuty podrzędne
results.response.text.actions.link
object
wymagane
Pokaż atrybuty podrzędne
results.response.text.actions.link.metadata
object
Pokaż atrybuty podrzędne
results.response.text.actions.link.metadata.description
object
Pokaż atrybuty podrzędne
results.response.text.actions.link.metadata.description.label
string
wymagane
results.response.text.actions.link.text
string
wymagane
results.response.text.actions.link.url
string
wymagane
results.response.text.actions.type
string
wymagane
Possible values: link
results.response.text.attachments
array of object
Pokaż atrybuty podrzędne
results.response.text.attachments.content
string
results.response.text.attachments.contentId
string
results.response.text.attachments.contentType
string
results.response.text.attachments.filename
string
wymagane
results.response.text.attachments.inline
boolean
results.response.text.attachments.mediaUrl
string
wymagane
results.response.text.metadata
object
Pokaż atrybuty podrzędne
results.response.text.metadata.apple
object
Pokaż atrybuty podrzędne
results.response.text.metadata.apple.appClipPreview
boolean
results.response.text.metadata.apple.appClipRegion
string
results.response.text.metadata.apple.summaryText
string
results.response.text.metadata.headers
object
results.response.text.metadata.line
object
Pokaż atrybuty podrzędne
results.response.text.metadata.line.emoji
object
Pokaż atrybuty podrzędne
results.response.text.metadata.line.emoji.items
array of object
Pokaż atrybuty podrzędne
results.response.text.metadata.line.emoji.items.emojiId
string
wymagane
results.response.text.metadata.line.emoji.items.index
integer
wymagane
results.response.text.metadata.line.emoji.items.length
integer
results.response.text.metadata.line.emoji.items.productId
string
wymagane
results.response.text.metadata.paymentDetails
object
Pokaż atrybuty podrzędne
results.response.text.metadata.paymentDetails.amount
string
wymagane
results.response.text.metadata.paymentDetails.currency
string
wymagane
results.response.text.metadata.paymentDetails.sessionIdentifier
string
results.response.text.metadata.paymentDetails.state
string
wymagane
results.response.text.metadata.subject
string
results.response.text.metadata.telegram
object
Pokaż atrybuty podrzędne
results.response.text.metadata.telegram.parseMode
string
results.response.text.metadata.whatsapp
object
Pokaż atrybuty podrzędne
results.response.text.metadata.whatsapp.callPermissionExpiration
string
results.response.text.metadata.whatsapp.callPermissionResponse
string
Possible values: accept, reject
results.response.text.metadata.whatsapp.previewUrl
boolean
wymagane
results.response.text.metadata.whatsapp.sharedContacts
array of object
Pokaż atrybuty podrzędne
results.response.text.metadata.whatsapp.sharedContacts.origin
string
wymagane
results.response.text.metadata.whatsapp.sharedContacts.phones
array of object
Pokaż atrybuty podrzędne
results.response.text.metadata.whatsapp.sharedContacts.phones.phone
string
wymagane
results.response.text.metadata.whatsapp.sharedContacts.phones.type
string
wymagane
results.response.text.metadata.whatsapp.sharedContacts.phones.waId
string
wymagane
results.response.text.metadata.whatsapp.sharedContacts.vcard
string
results.response.text.text
string
wymagane
results.response.type
string
wymagane
Possible values: text
results.language
string
The optional user-defined language of the macro.
results.usageCount
integer
results.tags
array of object
Pokaż atrybuty podrzędne
results.tags.id
string
wymagane
results.tags.name
string
wymagane
results.tags.description
string
wymagane
results.tags.status
string
wymagane
Possible values: draft, active, deleted
results.tags.category
object
Pokaż atrybuty podrzędne
results.tags.category.id
string
wymagane
results.tags.category.name
string
wymagane
results.tags.category.description
string
wymagane
results.tags.category.icon
string
Possible values: none, language, product, location, intent, department
results.tags.category.emoji
string
wymagane
results.tags.category.createdAt
string
wymagane
results.tags.category.updatedAt
string
wymagane
results.tags.agentCount
integer
results.tags.itemCount
integer
results.tags.macroCount
integer
results.tags.createdAt
string
wymagane
results.tags.updatedAt
string
wymagane
results.tags.deletedAt
string
results.tags.lastUsed
object
Pokaż atrybuty podrzędne
results.tags.lastUsed.addedToItemAt
string
results.tags.lastUsed.addedToItemId
string
results.tags.lastUsed.removedFromItemAt
string
results.tags.lastUsed.removedFromItemId
string
results.createdAt
string
wymagane
results.updatedAt
string
wymagane
results.actions
array of object
A list of macro actions to be executed. The order of actions may be changed by the service.
Pokaż atrybuty podrzędne
results.actions.type
string
wymagane
The type of this action.
results.actions.params
object
The parameters of this action. The accepted keys and values are defined by the action type.
results.actions.source
object
The source of this action. If received in a response, should be passed as-is in a subsequent request.
Pokaż atrybuty podrzędne
results.actions.source.macroId
string
wymagane
results.actions.source.actionId
string
wymagane
results.actions.outcome
string
The outcome of executing this action.
Possible values: OK, Error, Skipped
results.actions.cause
string
The cause of the outcome of this action, if the outcome is Error.
nextPageToken
string
The token that can be passed as pageToken in URL to retrieve the next set of results. If missing, no more results to display.
Przykład kodu
curl -X GET 'https://api.bird.com/workspaces/{workspaceId}/macros' \
  -H 'Authorization: AccessKey YOUR_ACCESS_KEY'
POST
/workspaces/{workspaceId}/macros
Add a new macro to a workspace.
Treść żądania
name
string
wymagane
The user-defined display name of the macro.
response
object
Pokaż parametry podrzędne
response.text
object
wymagane
Pokaż parametry podrzędne
response.text.actions
array of object
Pokaż parametry podrzędne
response.text.actions.link
object
wymagane
Pokaż parametry podrzędne
response.text.actions.link.metadata
object
Pokaż parametry podrzędne
response.text.actions.link.metadata.description
object
Pokaż parametry podrzędne
response.text.actions.link.metadata.description.label
string
wymagane
response.text.actions.link.text
string
wymagane
response.text.actions.link.url
string
wymagane
response.text.actions.type
string
wymagane
Possible values: link
response.text.attachments
array of object
Pokaż parametry podrzędne
response.text.attachments.content
string
response.text.attachments.contentId
string
response.text.attachments.contentType
string
response.text.attachments.filename
string
wymagane
response.text.attachments.inline
boolean
response.text.attachments.mediaUrl
string
wymagane
response.text.metadata
object
Pokaż parametry podrzędne
response.text.metadata.apple
object
Pokaż parametry podrzędne
response.text.metadata.apple.appClipPreview
boolean
response.text.metadata.apple.appClipRegion
string
response.text.metadata.apple.summaryText
string
response.text.metadata.headers
object
response.text.metadata.line
object
Pokaż parametry podrzędne
response.text.metadata.line.emoji
object
Pokaż parametry podrzędne
response.text.metadata.line.emoji.items
array of object
Pokaż parametry podrzędne
response.text.metadata.line.emoji.items.emojiId
string
wymagane
response.text.metadata.line.emoji.items.index
integer
wymagane
response.text.metadata.line.emoji.items.length
integer
response.text.metadata.line.emoji.items.productId
string
wymagane
response.text.metadata.paymentDetails
object
Pokaż parametry podrzędne
response.text.metadata.paymentDetails.amount
string
wymagane
response.text.metadata.paymentDetails.currency
string
wymagane
response.text.metadata.paymentDetails.sessionIdentifier
string
response.text.metadata.paymentDetails.state
string
wymagane
response.text.metadata.subject
string
response.text.metadata.telegram
object
Pokaż parametry podrzędne
response.text.metadata.telegram.parseMode
string
response.text.metadata.whatsapp
object
Pokaż parametry podrzędne
response.text.metadata.whatsapp.callPermissionExpiration
string
response.text.metadata.whatsapp.callPermissionResponse
string
Possible values: accept, reject
response.text.metadata.whatsapp.previewUrl
boolean
wymagane
response.text.metadata.whatsapp.sharedContacts
array of object
Pokaż parametry podrzędne
response.text.metadata.whatsapp.sharedContacts.origin
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones
array of object
Pokaż parametry podrzędne
response.text.metadata.whatsapp.sharedContacts.phones.phone
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones.type
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones.waId
string
wymagane
response.text.metadata.whatsapp.sharedContacts.vcard
string
response.text.text
string
wymagane
response.type
string
wymagane
Possible values: text
language
string
The optional user-defined language of the macro.
tagIds
array of string
The list of tag IDs to associate with the macro.
actions
array of object
A list of macro actions to be executed. The order of actions may be changed by the service.
Pokaż parametry podrzędne
actions.type
string
wymagane
The type of this action.
actions.params
object
The parameters of this action. The accepted keys and values are defined by the action type.
actions.source
object
The source of this action. If received in a response, should be passed as-is in a subsequent request.
Pokaż parametry podrzędne
actions.source.macroId
string
wymagane
actions.source.actionId
string
wymagane
actions.outcome
string
The outcome of executing this action.
Possible values: OK, Error, Skipped
actions.cause
string
The cause of the outcome of this action, if the outcome is Error.
Treść odpowiedzi
id
string
wymagane
name
string
wymagane
The user-defined display name of the macro.
response
object
Pokaż atrybuty podrzędne
response.text
object
wymagane
Pokaż atrybuty podrzędne
response.text.actions
array of object
Pokaż atrybuty podrzędne
response.text.actions.link
object
wymagane
Pokaż atrybuty podrzędne
response.text.actions.link.metadata
object
Pokaż atrybuty podrzędne
response.text.actions.link.metadata.description
object
Pokaż atrybuty podrzędne
response.text.actions.link.metadata.description.label
string
wymagane
response.text.actions.link.text
string
wymagane
response.text.actions.link.url
string
wymagane
response.text.actions.type
string
wymagane
Possible values: link
response.text.attachments
array of object
Pokaż atrybuty podrzędne
response.text.attachments.content
string
response.text.attachments.contentId
string
response.text.attachments.contentType
string
response.text.attachments.filename
string
wymagane
response.text.attachments.inline
boolean
response.text.attachments.mediaUrl
string
wymagane
response.text.metadata
object
Pokaż atrybuty podrzędne
response.text.metadata.apple
object
Pokaż atrybuty podrzędne
response.text.metadata.apple.appClipPreview
boolean
response.text.metadata.apple.appClipRegion
string
response.text.metadata.apple.summaryText
string
response.text.metadata.headers
object
response.text.metadata.line
object
Pokaż atrybuty podrzędne
response.text.metadata.line.emoji
object
Pokaż atrybuty podrzędne
response.text.metadata.line.emoji.items
array of object
Pokaż atrybuty podrzędne
response.text.metadata.line.emoji.items.emojiId
string
wymagane
response.text.metadata.line.emoji.items.index
integer
wymagane
response.text.metadata.line.emoji.items.length
integer
response.text.metadata.line.emoji.items.productId
string
wymagane
response.text.metadata.paymentDetails
object
Pokaż atrybuty podrzędne
response.text.metadata.paymentDetails.amount
string
wymagane
response.text.metadata.paymentDetails.currency
string
wymagane
response.text.metadata.paymentDetails.sessionIdentifier
string
response.text.metadata.paymentDetails.state
string
wymagane
response.text.metadata.subject
string
response.text.metadata.telegram
object
Pokaż atrybuty podrzędne
response.text.metadata.telegram.parseMode
string
response.text.metadata.whatsapp
object
Pokaż atrybuty podrzędne
response.text.metadata.whatsapp.callPermissionExpiration
string
response.text.metadata.whatsapp.callPermissionResponse
string
Possible values: accept, reject
response.text.metadata.whatsapp.previewUrl
boolean
wymagane
response.text.metadata.whatsapp.sharedContacts
array of object
Pokaż atrybuty podrzędne
response.text.metadata.whatsapp.sharedContacts.origin
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones
array of object
Pokaż atrybuty podrzędne
response.text.metadata.whatsapp.sharedContacts.phones.phone
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones.type
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones.waId
string
wymagane
response.text.metadata.whatsapp.sharedContacts.vcard
string
response.text.text
string
wymagane
response.type
string
wymagane
Possible values: text
language
string
The optional user-defined language of the macro.
usageCount
integer
tags
array of object
Pokaż atrybuty podrzędne
tags.id
string
wymagane
tags.name
string
wymagane
tags.description
string
wymagane
tags.status
string
wymagane
Possible values: draft, active, deleted
tags.category
object
Pokaż atrybuty podrzędne
tags.category.id
string
wymagane
tags.category.name
string
wymagane
tags.category.description
string
wymagane
tags.category.icon
string
Possible values: none, language, product, location, intent, department
tags.category.emoji
string
wymagane
tags.category.createdAt
string
wymagane
tags.category.updatedAt
string
wymagane
tags.agentCount
integer
tags.itemCount
integer
tags.macroCount
integer
tags.createdAt
string
wymagane
tags.updatedAt
string
wymagane
tags.deletedAt
string
tags.lastUsed
object
Pokaż atrybuty podrzędne
tags.lastUsed.addedToItemAt
string
tags.lastUsed.addedToItemId
string
tags.lastUsed.removedFromItemAt
string
tags.lastUsed.removedFromItemId
string
createdAt
string
wymagane
updatedAt
string
wymagane
actions
array of object
A list of macro actions to be executed. The order of actions may be changed by the service.
Pokaż atrybuty podrzędne
actions.type
string
wymagane
The type of this action.
actions.params
object
The parameters of this action. The accepted keys and values are defined by the action type.
actions.source
object
The source of this action. If received in a response, should be passed as-is in a subsequent request.
Pokaż atrybuty podrzędne
actions.source.macroId
string
wymagane
actions.source.actionId
string
wymagane
actions.outcome
string
The outcome of executing this action.
Possible values: OK, Error, Skipped
actions.cause
string
The cause of the outcome of this action, if the outcome is Error.
Przykład kodu
curl -X POST 'https://api.bird.com/workspaces/{workspaceId}/macros' \
  -H 'Authorization: AccessKey YOUR_ACCESS_KEY'
GET
/workspaces/{workspaceId}/macros/{macroId}
Retrieve information about a specific macro.
Treść odpowiedzi
id
string
wymagane
name
string
wymagane
The user-defined display name of the macro.
response
object
Pokaż atrybuty podrzędne
response.text
object
wymagane
Pokaż atrybuty podrzędne
response.text.actions
array of object
Pokaż atrybuty podrzędne
response.text.actions.link
object
wymagane
Pokaż atrybuty podrzędne
response.text.actions.link.metadata
object
Pokaż atrybuty podrzędne
response.text.actions.link.metadata.description
object
Pokaż atrybuty podrzędne
response.text.actions.link.metadata.description.label
string
wymagane
response.text.actions.link.text
string
wymagane
response.text.actions.link.url
string
wymagane
response.text.actions.type
string
wymagane
Possible values: link
response.text.attachments
array of object
Pokaż atrybuty podrzędne
response.text.attachments.content
string
response.text.attachments.contentId
string
response.text.attachments.contentType
string
response.text.attachments.filename
string
wymagane
response.text.attachments.inline
boolean
response.text.attachments.mediaUrl
string
wymagane
response.text.metadata
object
Pokaż atrybuty podrzędne
response.text.metadata.apple
object
Pokaż atrybuty podrzędne
response.text.metadata.apple.appClipPreview
boolean
response.text.metadata.apple.appClipRegion
string
response.text.metadata.apple.summaryText
string
response.text.metadata.headers
object
response.text.metadata.line
object
Pokaż atrybuty podrzędne
response.text.metadata.line.emoji
object
Pokaż atrybuty podrzędne
response.text.metadata.line.emoji.items
array of object
Pokaż atrybuty podrzędne
response.text.metadata.line.emoji.items.emojiId
string
wymagane
response.text.metadata.line.emoji.items.index
integer
wymagane
response.text.metadata.line.emoji.items.length
integer
response.text.metadata.line.emoji.items.productId
string
wymagane
response.text.metadata.paymentDetails
object
Pokaż atrybuty podrzędne
response.text.metadata.paymentDetails.amount
string
wymagane
response.text.metadata.paymentDetails.currency
string
wymagane
response.text.metadata.paymentDetails.sessionIdentifier
string
response.text.metadata.paymentDetails.state
string
wymagane
response.text.metadata.subject
string
response.text.metadata.telegram
object
Pokaż atrybuty podrzędne
response.text.metadata.telegram.parseMode
string
response.text.metadata.whatsapp
object
Pokaż atrybuty podrzędne
response.text.metadata.whatsapp.callPermissionExpiration
string
response.text.metadata.whatsapp.callPermissionResponse
string
Possible values: accept, reject
response.text.metadata.whatsapp.previewUrl
boolean
wymagane
response.text.metadata.whatsapp.sharedContacts
array of object
Pokaż atrybuty podrzędne
response.text.metadata.whatsapp.sharedContacts.origin
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones
array of object
Pokaż atrybuty podrzędne
response.text.metadata.whatsapp.sharedContacts.phones.phone
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones.type
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones.waId
string
wymagane
response.text.metadata.whatsapp.sharedContacts.vcard
string
response.text.text
string
wymagane
response.type
string
wymagane
Possible values: text
language
string
The optional user-defined language of the macro.
usageCount
integer
tags
array of object
Pokaż atrybuty podrzędne
tags.id
string
wymagane
tags.name
string
wymagane
tags.description
string
wymagane
tags.status
string
wymagane
Possible values: draft, active, deleted
tags.category
object
Pokaż atrybuty podrzędne
tags.category.id
string
wymagane
tags.category.name
string
wymagane
tags.category.description
string
wymagane
tags.category.icon
string
Possible values: none, language, product, location, intent, department
tags.category.emoji
string
wymagane
tags.category.createdAt
string
wymagane
tags.category.updatedAt
string
wymagane
tags.agentCount
integer
tags.itemCount
integer
tags.macroCount
integer
tags.createdAt
string
wymagane
tags.updatedAt
string
wymagane
tags.deletedAt
string
tags.lastUsed
object
Pokaż atrybuty podrzędne
tags.lastUsed.addedToItemAt
string
tags.lastUsed.addedToItemId
string
tags.lastUsed.removedFromItemAt
string
tags.lastUsed.removedFromItemId
string
createdAt
string
wymagane
updatedAt
string
wymagane
actions
array of object
A list of macro actions to be executed. The order of actions may be changed by the service.
Pokaż atrybuty podrzędne
actions.type
string
wymagane
The type of this action.
actions.params
object
The parameters of this action. The accepted keys and values are defined by the action type.
actions.source
object
The source of this action. If received in a response, should be passed as-is in a subsequent request.
Pokaż atrybuty podrzędne
actions.source.macroId
string
wymagane
actions.source.actionId
string
wymagane
actions.outcome
string
The outcome of executing this action.
Possible values: OK, Error, Skipped
actions.cause
string
The cause of the outcome of this action, if the outcome is Error.
Przykład kodu
curl -X GET 'https://api.bird.com/workspaces/{workspaceId}/macros/{macroId}' \
  -H 'Authorization: AccessKey YOUR_ACCESS_KEY'
PATCH
/workspaces/{workspaceId}/macros/{macroId}
Modify fields of a specific macro.
Treść żądania
name
string
The user-defined display name of the macro.
response
object
Pokaż parametry podrzędne
response.text
object
wymagane
Pokaż parametry podrzędne
response.text.actions
array of object
Pokaż parametry podrzędne
response.text.actions.link
object
wymagane
Pokaż parametry podrzędne
response.text.actions.link.metadata
object
Pokaż parametry podrzędne
response.text.actions.link.metadata.description
object
Pokaż parametry podrzędne
response.text.actions.link.metadata.description.label
string
wymagane
response.text.actions.link.text
string
wymagane
response.text.actions.link.url
string
wymagane
response.text.actions.type
string
wymagane
Possible values: link
response.text.attachments
array of object
Pokaż parametry podrzędne
response.text.attachments.content
string
response.text.attachments.contentId
string
response.text.attachments.contentType
string
response.text.attachments.filename
string
wymagane
response.text.attachments.inline
boolean
response.text.attachments.mediaUrl
string
wymagane
response.text.metadata
object
Pokaż parametry podrzędne
response.text.metadata.apple
object
Pokaż parametry podrzędne
response.text.metadata.apple.appClipPreview
boolean
response.text.metadata.apple.appClipRegion
string
response.text.metadata.apple.summaryText
string
response.text.metadata.headers
object
response.text.metadata.line
object
Pokaż parametry podrzędne
response.text.metadata.line.emoji
object
Pokaż parametry podrzędne
response.text.metadata.line.emoji.items
array of object
Pokaż parametry podrzędne
response.text.metadata.line.emoji.items.emojiId
string
wymagane
response.text.metadata.line.emoji.items.index
integer
wymagane
response.text.metadata.line.emoji.items.length
integer
response.text.metadata.line.emoji.items.productId
string
wymagane
response.text.metadata.paymentDetails
object
Pokaż parametry podrzędne
response.text.metadata.paymentDetails.amount
string
wymagane
response.text.metadata.paymentDetails.currency
string
wymagane
response.text.metadata.paymentDetails.sessionIdentifier
string
response.text.metadata.paymentDetails.state
string
wymagane
response.text.metadata.subject
string
response.text.metadata.telegram
object
Pokaż parametry podrzędne
response.text.metadata.telegram.parseMode
string
response.text.metadata.whatsapp
object
Pokaż parametry podrzędne
response.text.metadata.whatsapp.callPermissionExpiration
string
response.text.metadata.whatsapp.callPermissionResponse
string
Possible values: accept, reject
response.text.metadata.whatsapp.previewUrl
boolean
wymagane
response.text.metadata.whatsapp.sharedContacts
array of object
Pokaż parametry podrzędne
response.text.metadata.whatsapp.sharedContacts.origin
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones
array of object
Pokaż parametry podrzędne
response.text.metadata.whatsapp.sharedContacts.phones.phone
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones.type
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones.waId
string
wymagane
response.text.metadata.whatsapp.sharedContacts.vcard
string
response.text.text
string
wymagane
response.type
string
wymagane
Possible values: text
language
string
The optional user-defined language of the macro.
tagIds
array of string
The list of tag IDs to associate with the macro. An empty list will remove all tags.
actions
array of object
A list of macro actions to be executed. The order of actions may be changed by the service.
Pokaż parametry podrzędne
actions.type
string
wymagane
The type of this action.
actions.params
object
The parameters of this action. The accepted keys and values are defined by the action type.
actions.source
object
The source of this action. If received in a response, should be passed as-is in a subsequent request.
Pokaż parametry podrzędne
actions.source.macroId
string
wymagane
actions.source.actionId
string
wymagane
actions.outcome
string
The outcome of executing this action.
Possible values: OK, Error, Skipped
actions.cause
string
The cause of the outcome of this action, if the outcome is Error.
Treść odpowiedzi
id
string
wymagane
name
string
wymagane
The user-defined display name of the macro.
response
object
Pokaż atrybuty podrzędne
response.text
object
wymagane
Pokaż atrybuty podrzędne
response.text.actions
array of object
Pokaż atrybuty podrzędne
response.text.actions.link
object
wymagane
Pokaż atrybuty podrzędne
response.text.actions.link.metadata
object
Pokaż atrybuty podrzędne
response.text.actions.link.metadata.description
object
Pokaż atrybuty podrzędne
response.text.actions.link.metadata.description.label
string
wymagane
response.text.actions.link.text
string
wymagane
response.text.actions.link.url
string
wymagane
response.text.actions.type
string
wymagane
Possible values: link
response.text.attachments
array of object
Pokaż atrybuty podrzędne
response.text.attachments.content
string
response.text.attachments.contentId
string
response.text.attachments.contentType
string
response.text.attachments.filename
string
wymagane
response.text.attachments.inline
boolean
response.text.attachments.mediaUrl
string
wymagane
response.text.metadata
object
Pokaż atrybuty podrzędne
response.text.metadata.apple
object
Pokaż atrybuty podrzędne
response.text.metadata.apple.appClipPreview
boolean
response.text.metadata.apple.appClipRegion
string
response.text.metadata.apple.summaryText
string
response.text.metadata.headers
object
response.text.metadata.line
object
Pokaż atrybuty podrzędne
response.text.metadata.line.emoji
object
Pokaż atrybuty podrzędne
response.text.metadata.line.emoji.items
array of object
Pokaż atrybuty podrzędne
response.text.metadata.line.emoji.items.emojiId
string
wymagane
response.text.metadata.line.emoji.items.index
integer
wymagane
response.text.metadata.line.emoji.items.length
integer
response.text.metadata.line.emoji.items.productId
string
wymagane
response.text.metadata.paymentDetails
object
Pokaż atrybuty podrzędne
response.text.metadata.paymentDetails.amount
string
wymagane
response.text.metadata.paymentDetails.currency
string
wymagane
response.text.metadata.paymentDetails.sessionIdentifier
string
response.text.metadata.paymentDetails.state
string
wymagane
response.text.metadata.subject
string
response.text.metadata.telegram
object
Pokaż atrybuty podrzędne
response.text.metadata.telegram.parseMode
string
response.text.metadata.whatsapp
object
Pokaż atrybuty podrzędne
response.text.metadata.whatsapp.callPermissionExpiration
string
response.text.metadata.whatsapp.callPermissionResponse
string
Possible values: accept, reject
response.text.metadata.whatsapp.previewUrl
boolean
wymagane
response.text.metadata.whatsapp.sharedContacts
array of object
Pokaż atrybuty podrzędne
response.text.metadata.whatsapp.sharedContacts.origin
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones
array of object
Pokaż atrybuty podrzędne
response.text.metadata.whatsapp.sharedContacts.phones.phone
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones.type
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones.waId
string
wymagane
response.text.metadata.whatsapp.sharedContacts.vcard
string
response.text.text
string
wymagane
response.type
string
wymagane
Possible values: text
language
string
The optional user-defined language of the macro.
usageCount
integer
tags
array of object
Pokaż atrybuty podrzędne
tags.id
string
wymagane
tags.name
string
wymagane
tags.description
string
wymagane
tags.status
string
wymagane
Possible values: draft, active, deleted
tags.category
object
Pokaż atrybuty podrzędne
tags.category.id
string
wymagane
tags.category.name
string
wymagane
tags.category.description
string
wymagane
tags.category.icon
string
Possible values: none, language, product, location, intent, department
tags.category.emoji
string
wymagane
tags.category.createdAt
string
wymagane
tags.category.updatedAt
string
wymagane
tags.agentCount
integer
tags.itemCount
integer
tags.macroCount
integer
tags.createdAt
string
wymagane
tags.updatedAt
string
wymagane
tags.deletedAt
string
tags.lastUsed
object
Pokaż atrybuty podrzędne
tags.lastUsed.addedToItemAt
string
tags.lastUsed.addedToItemId
string
tags.lastUsed.removedFromItemAt
string
tags.lastUsed.removedFromItemId
string
createdAt
string
wymagane
updatedAt
string
wymagane
actions
array of object
A list of macro actions to be executed. The order of actions may be changed by the service.
Pokaż atrybuty podrzędne
actions.type
string
wymagane
The type of this action.
actions.params
object
The parameters of this action. The accepted keys and values are defined by the action type.
actions.source
object
The source of this action. If received in a response, should be passed as-is in a subsequent request.
Pokaż atrybuty podrzędne
actions.source.macroId
string
wymagane
actions.source.actionId
string
wymagane
actions.outcome
string
The outcome of executing this action.
Possible values: OK, Error, Skipped
actions.cause
string
The cause of the outcome of this action, if the outcome is Error.
Przykład kodu
curl -X PATCH 'https://api.bird.com/workspaces/{workspaceId}/macros/{macroId}' \
  -H 'Authorization: AccessKey YOUR_ACCESS_KEY'
DELETE
/workspaces/{workspaceId}/macros/{macroId}
Remove a specific macro.
Przykład kodu
curl -X DELETE 'https://api.bird.com/workspaces/{workspaceId}/macros/{macroId}' \
  -H 'Authorization: AccessKey YOUR_ACCESS_KEY'
POST
/workspaces/{workspaceId}/macros/{macroId}/preview
Retrieves the macro with variable substitutions applied to the response body.
Treść żądania
itemId
string
The ID of the feed item to source variables from. May be omitted where no feed item exists.
contactId
string
The ID of the contact to source variables from. If not provided, the macro will attempt to find a contact from the feed item.
contact
object
Pokaż parametry podrzędne
The ID of the contact to source variables from. If not provided, the macro will attempt to find a contact from the feed item.
contact.id
string
wymagane
actions
array of object
A list of macro actions to be executed. The order of actions may be changed by the service.
Pokaż parametry podrzędne
actions.type
string
wymagane
The type of this action.
actions.params
object
The parameters of this action. The accepted keys and values are defined by the action type.
actions.source
object
The source of this action. If received in a response, should be passed as-is in a subsequent request.
Pokaż parametry podrzędne
actions.source.macroId
string
wymagane
actions.source.actionId
string
wymagane
actions.outcome
string
The outcome of executing this action.
Possible values: OK, Error, Skipped
actions.cause
string
The cause of the outcome of this action, if the outcome is Error.
Treść odpowiedzi
response
object
Pokaż atrybuty podrzędne
response.text
object
wymagane
Pokaż atrybuty podrzędne
response.text.actions
array of object
Pokaż atrybuty podrzędne
response.text.actions.link
object
wymagane
Pokaż atrybuty podrzędne
response.text.actions.link.metadata
object
Pokaż atrybuty podrzędne
response.text.actions.link.metadata.description
object
Pokaż atrybuty podrzędne
response.text.actions.link.metadata.description.label
string
wymagane
response.text.actions.link.text
string
wymagane
response.text.actions.link.url
string
wymagane
response.text.actions.type
string
wymagane
Possible values: link
response.text.attachments
array of object
Pokaż atrybuty podrzędne
response.text.attachments.content
string
response.text.attachments.contentId
string
response.text.attachments.contentType
string
response.text.attachments.filename
string
wymagane
response.text.attachments.inline
boolean
response.text.attachments.mediaUrl
string
wymagane
response.text.metadata
object
Pokaż atrybuty podrzędne
response.text.metadata.apple
object
Pokaż atrybuty podrzędne
response.text.metadata.apple.appClipPreview
boolean
response.text.metadata.apple.appClipRegion
string
response.text.metadata.apple.summaryText
string
response.text.metadata.headers
object
response.text.metadata.line
object
Pokaż atrybuty podrzędne
response.text.metadata.line.emoji
object
Pokaż atrybuty podrzędne
response.text.metadata.line.emoji.items
array of object
Pokaż atrybuty podrzędne
response.text.metadata.line.emoji.items.emojiId
string
wymagane
response.text.metadata.line.emoji.items.index
integer
wymagane
response.text.metadata.line.emoji.items.length
integer
response.text.metadata.line.emoji.items.productId
string
wymagane
response.text.metadata.paymentDetails
object
Pokaż atrybuty podrzędne
response.text.metadata.paymentDetails.amount
string
wymagane
response.text.metadata.paymentDetails.currency
string
wymagane
response.text.metadata.paymentDetails.sessionIdentifier
string
response.text.metadata.paymentDetails.state
string
wymagane
response.text.metadata.subject
string
response.text.metadata.telegram
object
Pokaż atrybuty podrzędne
response.text.metadata.telegram.parseMode
string
response.text.metadata.whatsapp
object
Pokaż atrybuty podrzędne
response.text.metadata.whatsapp.callPermissionExpiration
string
response.text.metadata.whatsapp.callPermissionResponse
string
Possible values: accept, reject
response.text.metadata.whatsapp.previewUrl
boolean
wymagane
response.text.metadata.whatsapp.sharedContacts
array of object
Pokaż atrybuty podrzędne
response.text.metadata.whatsapp.sharedContacts.origin
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones
array of object
Pokaż atrybuty podrzędne
response.text.metadata.whatsapp.sharedContacts.phones.phone
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones.type
string
wymagane
response.text.metadata.whatsapp.sharedContacts.phones.waId
string
wymagane
response.text.metadata.whatsapp.sharedContacts.vcard
string
response.text.text
string
wymagane
response.type
string
wymagane
Possible values: text
actions
array of object
A list of macro actions to be executed. The order of actions may be changed by the service.
Pokaż atrybuty podrzędne
actions.type
string
wymagane
The type of this action.
actions.params
object
The parameters of this action. The accepted keys and values are defined by the action type.
actions.source
object
The source of this action. If received in a response, should be passed as-is in a subsequent request.
Pokaż atrybuty podrzędne
actions.source.macroId
string
wymagane
actions.source.actionId
string
wymagane
actions.outcome
string
The outcome of executing this action.
Possible values: OK, Error, Skipped
actions.cause
string
The cause of the outcome of this action, if the outcome is Error.
Przykład kodu
curl -X POST 'https://api.bird.com/workspaces/{workspaceId}/macros/{macroId}/preview' \
  -H 'Authorization: AccessKey YOUR_ACCESS_KEY'