Clara-Backend
  1. Stripe
Clara-Backend
  • Get Started
  • Quickstart (Rest API)
  • Quickstart (MCP Server)
  • Auth
    • Register
      POST
    • Google OAuth
      POST
    • Login
      POST
    • Logout
      DELETE
    • Change Password
      PATCH
    • Send OTP
      POST
    • Activate
      POST
    • Enable 2FA
      POST
    • Disable 2FA
      DELETE
  • User
    • View
      GET
    • Update
      PATCH
  • API Key
    • View
      GET
    • Reset
      POST
  • Transaction
    • View All
      GET
    • View
      GET
  • Task
    • View All
      GET
    • View
      GET
  • Agent
    • Supported Attachments
      GET
    • Analysis
      POST
  • Stripe
    • Rate
      GET
    • Portal
      POST
    • Buy
      POST
  • Misc
    • Health
    • Version
  1. Stripe

Buy

Prod Env
https://backend.clara.crazi.co/api/v1
Prod Env
https://backend.clara.crazi.co/api/v1
POST
https://backend.clara.crazi.co/api/v1
/stripe/buy
This endpoint lets a user buy credits in USD using Stripe checkout session hosted page.
Before purchasing, please fetch the rate using the Rate endpoint. Credits can only be bought between the lower_limit and upper_limit. Any amount outside of the limit will not be credited. For bigger purchases please reach out to us at hello@crazi.co.

Request

Authorization
Bearer Token
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
Bearer Token
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
or
Header Params

Body Params application/json

Examples

Responses

🟢201Success
text/plain
Body

🟠400Bad Request
🟠401Unauthorized
🟠404Resource Not Found
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://backend.clara.crazi.co/api/v1/stripe/buy' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data-raw '{
  "amount": 5,
  "return_path": ""
}'
Response Response Example
201 - Success
{
  "data": {
    "return_path": "",
    "url": "https://checkout.stripe.com/c/pay/cs_test_b1VbQddiB8glIwXq9TJrqDwnrHm4ukkRV1VewkBbb7Zq96ms5HYfqBYMe2#fidnandhYHdWcXxpYCc%2FJ2FgY2RwaXEnKSdqd2xibGtGamtxYH1xJz8ncmBnJyknZHVsTmB8Jz8ndW5acWB2cVowNFZDdzdoTnJcazB3T3U8S2YwMmtNZH1Kd1djUEtfYWpzQ1ZBQ3UwYTcwfX1GVzZNMTx8dUtjM0Y9Y19Qb1dMSHxPSkZMVnJMNDJvME5QcEZnXDQxQ31pQjU1NEhddGNsQFEnKSdjd2poVmB3c2B3Jz9xd3BgKSdnZGZuYndqcGthRmppancnPycmY2NjY2NjJyknaWR8anBxUXx1YCc%2FJ2hwaXFsWmxxYGgnKSdga2RnaWBVaWRmYG1qaWFgd3YnP3F3cGB4JSUl",
    "value_in_credits": 500,
    "value_in_fiat": 5
  },
  "message": "Checkout session created successfully.",
  "status": "success"
}
Modified at 2025-11-27 07:45:44
Previous
Portal
Next
Misc
Built with