Skip to main content
PATCH
/
enrollments
/
{id}
Change the status of an enrollment
curl --request PATCH \
  --url http://localhost:{port}/enrollments/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "status": "approved",
  "review_comment": "Good Choice"
}
'
{
  "id": "d4add56e-c345-4ac9-b392-7a890a60559a",
  "name": "Benjamin Zhang",
  "email": "[email protected]",
  "product_id": "393dea2f-1db7-4ffd-9527-d7b89ca59375",
  "comment": "come on",
  "status": "approved",
  "created_at": "2023-05-06T00:00:00Z",
  "updated_at": "2023-05-06T00:00:00Z",
  "created_by": "98d91cd7-860d-4869-937a-5af32eff2f4a",
  "updated_by": "98d91cd7-860d-4869-937a-5af32eff2f4a"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

X-API-Version
enum<string>
default:v1

Your API version

Available options:
v1
Content-Type
enum<string>
Available options:
application/json,
application/xml,
application/x-www-form-urlencoded,
application/octet-stream,
application/pdf,
text/plain,
text/html,
multipart/form-data

Path Parameters

id
string
required

Body

application/json
status
enum<string>
required
Available options:
pending,
processing,
rejected,
approved
Example:

"approved"

review_comment
string
Example:

"Good Choice"

Response

Success

id
string<uuid>
required
Example:

"e0e50a85-ddfa-44cf-8cc4-1cd76c06bc54"

name
string
required
Example:

"Benjamin Zhang"

email
string<email>
required
product_id
string<uuid>
required
Example:

"9068ec25-b433-4bc4-8e99-bbbc4de2d43d"

comment
string
required
Example:

"Let me in!"

created_at
string<date-time>
required
Example:

"2023-05-07T00:00:00Z"

updated_at
string<date-time>
required
Example:

"2023-05-07T00:00:00Z"

status
enum<string>
Available options:
pending,
processing,
rejected,
approved
Example:

"pending"

created_by
string<uuid>

REQUIRE metadata permissions

Example:

"98d91cd7-860d-4869-937a-5af32eff2f4a"

updated_by
string<uuid>

REQUIRE metadata permissions

Example:

"98d91cd7-860d-4869-937a-5af32eff2f4a"