Skip to content

Update a credit

PATCH
/credits/{id}
curl --request PATCH \
--url https://apisandbox.puurk.com/credits/example \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "id": "example", "oid": "example", "name": "example", "description": "example", "default_amount": 1, "max_amount": 1, "default_percentage": 1, "max_percentage": 1 }'

Update an existing credit

id
required
string

ID of the credit

Request body

Media typeapplication/json
object
id
string
oid

Organization ID

string
name
string
description
string
default_amount

Default credit amount in cents

integer
max_amount

Maximum credit amount in cents

integer
default_percentage
number
max_percentage
number
Examplegenerated
{
"id": "example",
"oid": "example",
"name": "example",
"description": "example",
"default_amount": 1,
"max_amount": 1,
"default_percentage": 1,
"max_percentage": 1
}

Credit updated

Media typeapplication/json
object
id
string
oid

Organization ID

string
name
string
description
string
default_amount

Default credit amount in cents

integer
max_amount

Maximum credit amount in cents

integer
default_percentage
number
max_percentage
number
Examplegenerated
{
"id": "example",
"oid": "example",
"name": "example",
"description": "example",
"default_amount": 1,
"max_amount": 1,
"default_percentage": 1,
"max_percentage": 1
}

Unauthorized

Not found