Create Code
Create Code API endpoint for Sweeppea. POST /codes. Complete documentation with code examples in cURL, JavaScript, and Python.
POST
/api/v3/codes
Description
This endpoint allows you to create code. Use this to manage your code/coupons data programmatically through the Sweeppea API.
Code Examples
curl -X POST "https://api-v3.sweeppea.com/codes" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"key": "value",
"name": "example"
}'
Response
200 OK
{
"success": true,
"data": {},
"message": "Operation completed successfully"
}