Skip to main content
POST
/
v1
/
aggregators
/
{raast-aggregator-id}
/
merchants
Create Merchant
curl --request POST \
  --url https://api.getsafepay.com/raastwire/v1/aggregators/{raast-aggregator-id}/merchants \
  --header 'Content-Type: application/json' \
  --header 'X-SFPY-AGGREGATOR-SECRET-KEY: <api-key>' \
  --data '
{
  "merchant_external_id": "sec_0c3de397-441f-471f-bcd7-b6d948e1c307",
  "iban": "PK62ABPA0010000222380013",
  "name": "TestingMerchant",
  "enabled": true,
  "raast_merchant_id": "mer_eb2f5757-c0e4-4eb4-ad4b-2f4b671a84e2",
  "rate_card": {
    "ratecard_kind": "RateCardKind_fixed",
    "variable_rate": 0.0215,
    "fixed_rate": 2900,
    "tax_rate": 0.1,
    "tax_region": "Punjab",
    "sales_tax_withholding": 0.1,
    "income_tax_withholding": 0.02
  }
}
'
{
  "api_version": "v1",
  "data": {
    "id": "0",
    "token": "am_d7fd05ea-8613-4038-afd7-4275f29110f5",
    "name": "TestingMerchant",
    "aggregator_id": "agg_2288490a-2176-4de5-b373-0ffb6f8e2e6e",
    "merchant_id": "mer_eb2f5757-c0e4-4eb4-ad4b-2f4b671a84e2",
    "merchant_external_id": "sec_0c3de397-441f-471f-bcd7-b6d948e1c307",
    "bank_account_id": "acc_a17a478a-f7cd-448b-9753-5729a6f237ad",
    "enabled": true,
    "created_at": "2025-05-21T09:36:42.586176361Z",
    "updated_at": "2025-05-21T09:36:42.586185862Z",
    "raast_merchant": {
      "id": "0",
      "token": "mer_eb2f5757-c0e4-4eb4-ad4b-2f4b671a84e2",
      "partner_id": "partner_ed4f0480-36c8-4a5a-8cd4-381bc4d83f2c",
      "raast_record_id": "480776",
      "status": "Inactive",
      "uid_type": "NTN",
      "uid_value": "33225247890431",
      "name": "TestHasMerchant",
      "document_type": "NTN",
      "document_number": "33225247890431",
      "address_details": {
        "country": "PK",
        "city": "Lahore",
        "state_province_region": "Punjab",
        "address_line": "h193c1 saddiq"
      },
      "contact_details": {
        "mobile_number": "+9233330226445",
        "email": "testing1702@gmail.com"
      },
      "additional_details": {
        "dba": "The best business 001",
        "mcc": "3434",
        "lat": "",
        "long": ""
      },
      "additional_details_private": {},
      "created_at": "2025-05-21T09:36:40.660619343Z",
      "updated_at": "2025-05-21T09:36:40.660619733Z"
    },
    "rate_card": {
      "id": "0",
      "token": "mrc_859bf970-6178-48c4-a801-014d027a9fe8",
      "aggregator_merchant_id": "am_d7fd05ea-8613-4038-afd7-4275f29110f5",
      "connector_id": "conn_eec2d68c-b72a-4f84-82ff-a7d4b3ebaa21",
      "rate_card_id": "rc_d0680a67-e8bc-4a39-a7c1-ee9998346f17",
      "created_at": "2025-05-21T09:36:42.586189872Z",
      "updated_at": "2025-05-21T09:36:42.586190032Z",
      "tax_rate": 0
    }
  }
}

Authorizations

X-SFPY-AGGREGATOR-SECRET-KEY
string
header
required

Path Parameters

raast-aggregator-id
string
required

The unique identifier for the aggregator

Example:

"agg_2288490a-2176-4de5-b373-0ffb6f8e2e6e"

Body

application/json

Request to create a merchant linked to an aggregator

Merchant creation payload specifying identifiers and pricing configuration

merchant_external_id
string
required

Client-supplied identifier that remains stable across Safepay integrations

iban
string
required

Settlement IBAN used for Raast payouts

name
string
required

Merchant display name

raast_merchant_id
string
required

Identifier of the previously onboarded Raast merchant to associate

rate_card
object
required

Rate configuration Safepay applies to Raast transactions

enabled
boolean

Indicates whether the merchant should be active immediately after creation

Response

This response contains details of a merchant

Standard response structure for successful operations

api_version
string

The current version of the API spec

Example:

"v1"

data
object

Merchant resource created under an aggregator for Raast transactions