πŸ–₯️Integration

First of all, request the Telegram Bot connection from a-pay support. After confirmation, follow these steps.

Step 0

If you don’t have your own bot already, create one with @BotFather, following Telegram instructions.

Step 1

Find the Paykassma Payments in Bot Settings

  • Type /mybots

  • Then choose your Bot

  • Choose Payments, then find and choose Paykassma (use buttons Β« and Β»)

  • Choose Connect Paykassma Live to connect the final integration or choose Connect Paykassma Test to test your bot. Test example described at Example

  • You will go to @paykassma_bot

Step 2

Send all the necessary Data from A-Pay Dashboard

The @paykassma_bot will request the following data:

  • apikey**:** (32 characters: [a-z0-9]{32})

  • project id**:** (up to 7 digits: [0-9]{1,7})

  • webhook id**:** (7 digits: [0-9]{7})

  • webhook access key**:** (32 characters: [a-z0-9]{32})

  • webhook private key**:** (32 characters: [a-z0-9]{32})

Note: if you choice Connect Paykassma Test, @BotFather will send you the token without requesting any data and you can skip this step

You can find this data on your A-pay Dashboard:

  • Open the A-pay Dashboard and choose table Projects

  • Copy and paste in Telegram apikey, project id, webhook access key and webhook private key of your project (use right-click and copy-button)

  • Then click OPEN PROJECT and find the row with Webhook depost URL: https://paykassmapayment-tgb.com/apay/deposit/postback

  • Copy and paste in Telegram the webhook id of this row (use right-click and copy-button)

Now you can send the data to @paykassma_bot. All the parameters must be included in a single message, each on a new line, in the following order

  1. apikey**:** (32 characters: [a-z0-9]{32})

  2. project id**:** (up to 7 digits: [0-9]{1,7})

  3. webhook id**:** (7 digits: [0-9]{7})

  4. webhook access key**:** (32 characters: [a-z0-9]{32})

  5. webhook private key**:** (32 characters: [a-z0-9]{32})

For example:

If the data is correct, @paykassma_bot will respond with: "The project data has been successfully saved"

Attention! Do not give this data to any third parties!

Step 3

Obtain the token from @BotFather

Once the data is saved, you can return to @BotFather to obtain the token to implement payments to your merchant bot.

Step 4

Pass the obtained token to your dev team, so they can use in implementation of Telegram Payments in your merchant bot. You can find the necessary methods for building your payment implementation in the Payments Section of the Bot API Manual.

Last updated