HSRCPAY Dökümantasyon
API v1

Create payment provider config

Handler may respond 200 or 201.

POST
/payment-provider-configs/

Authorization

bearerAuth
AuthorizationBearer <token>

Use Authorization: Bearer <token>. The same header supports: (1) JWT access token from the configured auth provider; (2) secret API key whose value contains sk_ within the first 32 characters (e.g. sk_live_…, sk_test_…); (3) publishable key containing pk_. Sandbox keys typically include _test_ in the string; the server resolves repositories from that.

In: header

Query Parameters

account_id*Account ID

Request Body

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://api.hsrcpay.com/v1/payment-provider-configs/?account_id=string" \  -H "Content-Type: application/json" \  -d '{    "name": "unnamed provider config",    "provider_identifier": "string",    "credentials": {      "property1": null,      "property2": null    },    "merchant_capabilities": {      "allowed_currencies": "*",      "allowed_payment_methods": "*"    }  }'
{
  "message": "success",
  "success": true,
  "data": {
    "object": "payment_provider_config",
    "id": "string",
    "account_id": "string",
    "name": "string",
    "payment_provider_id": "string",
    "credentials": null,
    "merchant_capabilities": null,
    "deleted": true,
    "created_at": null,
    "updated_at": null,
    "fees": [
      {
        "object": "payment_provider_config_fee",
        "id": "string",
        "payment_provider_config_id": "string",
        "payment_provider_method_id": "string",
        "installment_count": 0,
        "volume_fee": 0,
        "fixed_fee_currency": "string",
        "fixed_fee": 0,
        "created_at": null,
        "updated_at": null,
        "property1": null,
        "property2": null
      }
    ],
    "routing_rules": [
      {
        "object": "payment_provider_config_routing_rule",
        "id": "string",
        "payment_provider_config_id": "string",
        "conditions": null,
        "created_at": null,
        "updated_at": null,
        "property1": null,
        "property2": null
      }
    ],
    "property1": null,
    "property2": null
  },
  "property1": null,
  "property2": null
}
{
  "message": "success",
  "success": true,
  "data": {
    "object": "payment_provider_config",
    "id": "string",
    "account_id": "string",
    "name": "string",
    "payment_provider_id": "string",
    "credentials": null,
    "merchant_capabilities": null,
    "deleted": true,
    "created_at": null,
    "updated_at": null,
    "fees": [
      {
        "object": "payment_provider_config_fee",
        "id": "string",
        "payment_provider_config_id": "string",
        "payment_provider_method_id": "string",
        "installment_count": 0,
        "volume_fee": 0,
        "fixed_fee_currency": "string",
        "fixed_fee": 0,
        "created_at": null,
        "updated_at": null,
        "property1": null,
        "property2": null
      }
    ],
    "routing_rules": [
      {
        "object": "payment_provider_config_routing_rule",
        "id": "string",
        "payment_provider_config_id": "string",
        "conditions": null,
        "created_at": null,
        "updated_at": null,
        "property1": null,
        "property2": null
      }
    ],
    "property1": null,
    "property2": null
  },
  "property1": null,
  "property2": null
}
{
  "message": "string",
  "success": false,
  "error": {
    "code": 0,
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    },
    "property1": null,
    "property2": null
  },
  "property1": null,
  "property2": null
}
{
  "message": "string",
  "success": false,
  "error": {
    "code": 0,
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    },
    "property1": null,
    "property2": null
  },
  "property1": null,
  "property2": null
}
{
  "message": "string",
  "success": false,
  "error": {
    "code": 0,
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    },
    "property1": null,
    "property2": null
  },
  "property1": null,
  "property2": null
}
{
  "message": "string",
  "success": false,
  "error": {
    "code": 0,
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    },
    "property1": null,
    "property2": null
  },
  "property1": null,
  "property2": null
}
{
  "message": "string",
  "success": false,
  "error": {
    "code": 0,
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    },
    "property1": null,
    "property2": null
  },
  "property1": null,
  "property2": null
}
{
  "message": "string",
  "success": false,
  "error": {
    "code": 0,
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    },
    "property1": null,
    "property2": null
  },
  "property1": null,
  "property2": null
}
{
  "message": "string",
  "success": false,
  "error": {
    "code": 0,
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    },
    "property1": null,
    "property2": null
  },
  "property1": null,
  "property2": null
}
{
  "message": "string",
  "success": false,
  "error": {
    "code": 0,
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    },
    "property1": null,
    "property2": null
  },
  "property1": null,
  "property2": null
}