Deactivate a subscription to stop collection.
Deactivate a subscription to stop collection.
Actors
Merchant / integratorclient
Calls the Payroc API to stop collection for the subscription.
Payroc gatewayapi
The Payroc API surface these steps call.
Sequence
Merchant / integrator
Payroc gateway
Follow the numbered steps in order. Each step is described under Steps.
Steps
Follow the workflow
Simulate API steps with synthetic inputs. Confirm manual steps yourself before continuing.
Interactive workflow tests are unavailable in this profile. Use the linked reference and source files to send API requests with your own client.
- 1
Deactivate subscription
API requestStops the gateway from taking further payments for the subscription. POST with no request body; returns 200.
Merchant / integrator → Payroc gateway
POST/processing-terminals/{processingTerminalId}/subscriptions/{subscriptionId}/deactivate
Arazzo workflow source
arazzo: 1.0.0
info:
title: Deactivate a subscription
summary: Stop the gateway from taking further payments for a subscription.
description: |
Stops collection on an existing subscription (a customer's assignment to a payment plan). POST with no request body; returns 200.
Agent gotchas:
- `subscriptionId` is the merchant-assigned string (for example
`SubRef7654`) used on create, not a gateway-generated id.
- `deactivateSubscription` requires no request body and no Idempotency-Key
header.
To restart collection later, use the reactivate-a-subscription workflow - deactivate and reactivate are mutually exclusive collection-state actions.
version: 1.0.0
sourceDescriptions:
- name: payroc-api
url: /openapi.yaml
type: openapi
workflows:
- workflowId: deactivate-a-subscription
x-actors:
- id: merchant
name: Merchant / integrator
type: client
description: Calls the Payroc API to stop collection for the subscription.
- id: payroc-gateway
name: Payroc gateway
type: api
description: The Payroc API surface these steps call.
summary: Deactivate a subscription to stop collection.
description: |
Stops the gateway from taking further payments for the subscription identified by `subscriptionId` on the terminal (deactivateSubscription). Returns 200.
inputs:
type: object
required:
- processingTerminalId
- subscriptionId
properties:
processingTerminalId:
type: string
description: Unique identifier for the terminal that owns the subscription.
example: "1234001"
subscriptionId:
type: string
description: Merchant-assigned identifier of the subscription to deactivate.
example: SubRef7654
steps:
- stepId: deactivateSubscription
x-actor: merchant
x-actor-to: payroc-gateway
x-label: deactivate request
description: |
Stops the gateway from taking further payments for the subscription. POST with no request body; returns 200.
operationId: deactivateSubscription
parameters:
- name: processingTerminalId
in: path
value: $inputs.processingTerminalId
- name: subscriptionId
in: path
value: $inputs.subscriptionId
successCriteria:
- condition: $statusCode == 200
outputs:
status: $response.body#/currentState/status
outputs:
status: $steps.deactivateSubscription.outputs.status