BaleMessenger icon

BaleMessenger

Interact with Bale Messenger API

Overview

The "Add Sticker To Set" operation in the Sticker resource allows users to add a new sticker to an existing sticker set on the Bale Messenger platform. This node is useful for bot developers or automation workflows that manage custom sticker sets dynamically, enabling them to expand sticker collections by uploading new stickers programmatically.

Typical use cases include:

  • Automatically adding newly created or user-submitted stickers to a predefined sticker set.
  • Managing and updating sticker sets as part of a chatbot's interactive features.
  • Enriching user engagement by expanding available stickers without manual intervention.

For example, a chatbot could allow users to submit images which are then converted into stickers and added to a shared sticker set accessible by all users.

Properties

Name Meaning
UserId The unique identifier of the user who owns the sticker set to which the sticker will be added.
Name The name of the existing sticker set where the new sticker will be added.
Binary Property The name of the binary property containing the sticker file data to upload (e.g., image data).

Output

The output JSON contains the response from the Bale Messenger API after attempting to add the sticker to the set. It typically includes success status and any relevant metadata returned by the API about the added sticker.

The node does not output binary data for this operation; it only returns JSON with the API response details.

Example output structure (simplified):

{
  "ok": true,
  "result": {
    // Details about the added sticker or confirmation message
  }
}

Dependencies

  • Requires an active Bale Messenger API credential with a valid authentication token.
  • The node uses the Bale Messenger API endpoint https://tapi.bale.ai/bot to perform operations.
  • Input binary data must be provided in a binary property of the input item, containing the sticker file data.

Troubleshooting

  • Invalid UserId or Sticker Set Name: Ensure the user ID corresponds to the owner of the sticker set and the sticker set name exists.
  • Binary Data Issues: The binary property must contain valid sticker file data. If the binary property is missing or incorrectly named, the upload will fail.
  • API Errors: Errors returned from the Bale Messenger API (e.g., permission denied, invalid file format) will be included in the node output. Check the error messages for guidance.
  • File Format: Make sure the sticker file format complies with Bale Messenger requirements (usually PNG or WEBP for stickers).
  • Credential Problems: Verify that the API token credential is correctly configured and has necessary permissions.

Links and References


This summary focuses exclusively on the "Add Sticker To Set" operation within the Sticker resource based on static analysis of the provided source code and properties.

Discussion