curl --request POST \
--url https://api-sandbox.appcharge.com/components/v1/badge \
--header 'Content-Type: application/json' \
--header 'x-publisher-token: <api-key>' \
--data '{
"name": "New Year Celebration",
"publisherBadgeId": "new_year_celebration",
"type": "emblem",
"badgeImageUrl": "https://example.com/images/new-year-ribbon.png"
}'
{
"id": "507f1f77bcf86cd799439011",
"name": "New Year Celebration",
"publisherBadgeId": "new_year_celebration",
"type": "emblem",
"badgeImageUrl": "https://cdn.appcharge.com/507f1f77bcf86cd799439011_emblem.png",
"badgeExternalImageUrl": "https://example.com/images/new-year-emblem.png"
}
Creates a badge.
curl --request POST \
--url https://api-sandbox.appcharge.com/components/v1/badge \
--header 'Content-Type: application/json' \
--header 'x-publisher-token: <api-key>' \
--data '{
"name": "New Year Celebration",
"publisherBadgeId": "new_year_celebration",
"type": "emblem",
"badgeImageUrl": "https://example.com/images/new-year-ribbon.png"
}'
{
"id": "507f1f77bcf86cd799439011",
"name": "New Year Celebration",
"publisherBadgeId": "new_year_celebration",
"type": "emblem",
"badgeImageUrl": "https://cdn.appcharge.com/507f1f77bcf86cd799439011_emblem.png",
"badgeExternalImageUrl": "https://example.com/images/new-year-emblem.png"
}
Publisher token, as displayed in the Publisher Dashboard.
Create an emblem badge.
Badge created successfully.
Response schema for an emblem badge.
Was this page helpful?