On this page

Payment Admission

A Payment Admission in the Paylias network represents the receiving end of a payment transaction. It tracks how a payment is processed and accepted by the receiving organization, providing status updates and validation results.

Creation and Delivery

Payment Admissions are automatically created following a successful Payment Submission. The creation process follows this sequence:

  1. A Payment is submitted via the Payment Submission endpoint
  2. Upon successful submission, a Payment Admission is automatically created
  3. The Payment Admission is delivered to the receiving party via webhooks

Important: To receive Payment Admissions, the receiving organization must have:

  • A valid webhook endpoint configured
  • The webhook endpoint enabled
  • A subscription to the RT_PaymentAdmissions resource type
  • A subscription to the EK_Created event kind

Without proper webhook configuration, Payment Admissions will still be created but the receiving party won't be notified of their existence.

Overview

Each Payment Admission:

  • Links to a specific Payment record
  • Tracks the admission status
  • Contains processing timing information
  • Includes relationships to related resources
  • Provides status reasoning when applicable

Payment Admission Resource

Property Type Required Description Notes
token string Yes Unique identifier for the admission Format: pay_adm_*
payment_id string Yes ID of the associated payment Must exist
organization_id string Yes Organization receiving the payment Auto-populated from auth
partner_id string Yes Partner under organization Auto-populated from auth
status enum Yes Current admission status See Status Values
status_reason string No Description of current status Optional context
admission_time int64 Yes Processing start timestamp Unix timestamp
relationships object No Related resources See Relationships Properties

Status Values

Value Description
Admission_None Initial state, not yet processed
Admission_Accepted Accepted and pending processing
Admission_DeliveryConfirmed Successfully processed and accepted
Admission_DeliveryFailed Rejected due to validation or other failure
Admission_ValidationPending Awaiting validation checks

Relationships Properties

Property Type Required Description
payment object No Complete payment record details

Example Response

{
    "ok": true,
    "data": {
        "token": "pay_adm_cvk3jvs20or8munut3mg",
        "payment_id": "cjes76vsemvj3obsnc52",
        "organization_id": "org_ct239n420or249k5bo90",
        "partner_id": "part_ct23b6420or249k5boag",
        "status": 1,
        "admission_time": 1743272447,
        "relationships": {
            "payment": {
                "payment_id": "cjes76vsemvj3obsnc52",
                "organization_id": "org_ct239n420or249k5bo90",
                "partner_id": "part_ct23b6420or249k5boag",
                "reference": "INV0001",
                "initiated_at": 1743270060,
                "expires_at": 1743273661,
                "amount": {
                    "currency": "USD",
                    "total": "10000"
                },
                "debtor_party": {
                    "payment_address": "john@stripe-platinum",
                    "first_name": "John",
                    "last_name": "Collison",
                    "email": "johnc@stripe.com",
                    "phone": "+16462442945",
                    "type": "Payee_Individual",
                    "billing": {
                        "country": "US"
                    }
                },
                "beneficiary_party": {
                    "payment_address": "ziyad@safepay-platinum",
                    "first_name": "Ziyad",
                    "last_name": "Parekh",
                    "email": "ziyad.parekh@gmail.com",
                    "phone": "+923008277879",
                    "type": "Payee_Individual",
                    "billing": {
                        "country": "US"
                    }
                },
                "device": {},
                "location": {}
            }
        }
    }
}

API Endpoints

Find Payment Admission

Retrieves details of a specific payment admission.

Required Headers

Header Description
X-Org-ID Organization identifier
X-Partner-ID Partner identifier
X-Sfpy-Api-Key API key for authentication

Path Parameters

Parameter Type Required Description
paymentId string Yes ID of the payment
admissionId string Yes ID of the admission

GET /api/v1/csp/payments/{paymentId}/admissions/{admissionId}

curl --location 'http://localhost:9001/api/v1/csp/payments/cjes76vsemvj3obsnc52/admissions/pay_adm_cvk3jvs20or8munut3mg' \
--header 'X-Org-ID: org_ct239n420or249k5bo90' \
--header 'X-Partner-ID: part_ct23b6420or249k5boag' \
--header 'X-Sfpy-Api-Key: AA5B7256D7E228329F9A7D6E58880D48'

Error Codes

Error Code Description
error.bad_request Invalid or missing required parameters
error.resource_not_found Payment or admission not found
error.unauthorized_access Invalid or missing authentication
Docs and examples licensed under MIT