Cancel a Subscription

🚧

Limited Availability

Access to the Compliance API is currently limited to approved partners. Endpoints, request/response shapes, and field names may change before reaching general availability — use against staging for early integration work and coordinate with your CorpNet account manager before relying on Compliance API calls in production-critical paths. Report issues or feedback to your account manager.

POST /v1/partners/{partnerId}/subscriptions/{subscriptionId}/cancel

Cancels a subscription. Behavior differs based on service category:

  • Registered Agent subscriptions require a replacement proof document (your customer's substitute RA confirmation, attached as base64-encoded file). CorpNet creates a cancellation request in Ready for Review status; final cancellation occurs after review.
  • All other service categories cancel immediately and the subscription status is set to Cancelled.

Path Parameters

ParameterTypeRequiredDescription
partnerIdStringYesYour Account PID.
subscriptionIdStringYesSubscription Plan identifier.

Request Body — Registered Agent cancellations

{
  "title": "RA Service Replacement Proof",
  "extension": "pdf",
  "base64": "JVBERi0xLjQKJeLjz9M..."
}
FieldTypeRequiredDescription
titleStringYesHuman-readable file title.
extensionStringYesFile extension without leading dot (e.g., pdf, png).
base64StringYesBase64-encoded file contents.

Request Body — non-RA cancellations

Send an empty object:

{}

Example

# Non-RA cancellation
curl -s -X POST \
  -H "Authorization: Bearer $ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{}' \
  "https://api.corpnet.com/v1/partners/P123456/subscriptions/a0S5e000001ABCD/cancel"

Response — 200 OK

{ "serviceId": "a0S5e000001ABCD", "status": "success" }
📘

Envelope note

This endpoint returns a flat { serviceId, status } shape — it does not use the standard { data, statusCode, message } envelope. Branch on the HTTP status code; the status string is human-readable.

Error Responses

{ "statusCode": 400, "message": "Subscripion plan is required.", "data": null }
{ "statusCode": 400, "message": "The subscription is already cancelled.", "data": null }
{ "statusCode": 400, "message": "\"title\", \"extension\", and \"base64\" are required.", "data": null }
CauseResolution
Subscription already cancelledInspect status via Get a Subscription before issuing the cancel.
Missing RA proof fieldsRegistered Agent cancellations require title, extension, and base64. Provide all three.
subscriptionId not foundConfirm the identifier is correct and belongs to your partner.

Notes

  • For Registered Agent cancellations, CorpNet's compliance team reviews the replacement proof before final cancellation takes effect. The HTTP 200 confirms the cancellation request was accepted into the review queue, not that the subscription is immediately cancelled.
  • The "Subscripion plan is required." error message is verbatim from the API — the misspelling is the actual server response. Parse on statusCode, not on message text.