PUT Update a Transaction

PUT: /disbursement/v1/transaction/{transactionId}

Overview

The Update API determines what information to collect from the customer, validates the data for compliance purposes and updates the transactionId resource with the data gathered.

Make a Request:

  1. Prepare headers & authentication

    The application must call the 'Update a Transaction' endpoint with a PUT HTTP method, providing the OAuth access_token and all other required header values.\

    NOTE: MoneyGram uses the OAuth 2.0 framework. The application must use their OAuth client credentials to generate an access_token by calling the Get Access Token endpoint. The token is valid for 1 hour and must be passed as a header value in all subsequent API HTTP calls. Learn More


  1. Provide the transactionId resource as a path parameter

    The application must pass the associated transactionId as a path parameter on the Update API. This will allow the application to update the transactionId resource with customer and transactional information. The transactionId will have been previously generated from the previous Quote or Create endpoints.\
  2. Provide body payload: "Transact by send amount" OR "Transact by receive amount"

    The application must use the oneOf Keyword to update a transaction by send or receive amount. At this point the application has the option to re-quote the transactionId:

    • Transact by send amount: The application must provide the destinationCountryCode , the sendAmount.value , sendAmount.currency and all other REQUIRED fields in the request.

      OR

    • Transact by receive amount: The application must provide the destinationCountryCode, receiveAmount.value , receiveAmount.currency and all other REQUIRED fields in the request.

      NOTE: The Update API uses ISO Standards for country and currency values. MoneyGram provides Reference Data APIs which can to queried to understand the supported values and associated metadata.


  1. Provide discounts to the request body (optional):

    The Quote API also allows the application to apply promotional discounts.
    • If a promotionalCodes is passed a discount will be applied to the fee quote.\
  2. Provide the sender, receiver and transactional REQUIRED fields to the request body

    The application must collect initiator, receiver and transactionDetails for MoneyGram to perform real-time validation and compliance screening:

    • If the customer has chosen to deposit funds in to their bank account, wallet or card then account information can be submitted in the targetAccount dynamic keys.

  3. Make a request and handle response

    The application must call 'Update a transaction' endpoint with a PUT HTTP method. The application must build to handle the following response scenarios:

    • Validation successful | 200 OK HTTP Status |"readyToCommit": true

      When the Update endpoint responds with a 200 HTTP Status and the "readytoCommit": true, the application can proceed to "Commit a transaction" API and execute the transfer fo funds.

      The Create API payload will also return the final transaction summary in the payload, typically including: transactionId, serviceOption, sendAmount, sendCurrency, fees, fxRate, discountsApplied and the receiveAmount. In some cases, send or receive side taxes are applied.\

      NOTE: The Update API response is typically displayed in the application UI as pre-payment disclosure for the customer to review and confirm. Quote and FxRate is locked for 30 minutes. Learn More\

    • Validation failed | 400 Bad Request HTTP Status |"readyToCommit": false

      When the Update endpoint responds with 400 HTTP Status and the "readytoCommit": false, the application cannot proceed to "Commit a transaction" API.

      The Update endpoint will return and array of error code object. The application must handle the errorCode, which could indicate a syntax error or missing fields. An array of offending fields will be returned for the application to correct and resubmit.

      The application can make repeated attempts on the UPDATE API until validation is successful.

      NOTE: In some scenario's, enhanced due diligence is need to be undertaken on the customer. A specific error code will be returned and an array of offending fields. The fields/values need to be provided and resubmitted on the Update API for further checks


  1. The application can call the Commit endpoint to execute the transfer when a 200 HTTP Success Status and the boolean "readyForCommit": true is returned on the Update response. The application must use the associated transactionId on the subsequent Commit API by providing it as a path parameter. The Commit endpoint is the final API call and will execute the transaction to MoneyGram.



Business rules to code

📘

  • Finalizing thetransactionId& executing the transfer of funds: When the readyForCommit field in the update a transaction is true, the application may continue the transaction. If there is an error or a problem with the transaction, an error message will be returned. Please refer to the Error Message {insert ling to error page here} document for list of errors. The application must send the update a transaction until the response returns a "readyForCommit": true

    * Making multiple PUT requests to Update thetransactionId: , if there are any changes needed for customer data after the Update a transaction endpoint responds, the application should call the Update endpoint to using the same transactionId and provide new customer/transactional data.

    * Enumerated fields: For all Enumerated Fields (some examples below), agent application must use the valid enumerations returned from the enumerations API response and allow only valid values to be selected. Learn More

    * Bank, mobile wallet & card deposit: The. application must code to all fields where dynamic = ‘true’, which is returned where serviceOptionName: "BANK_DEPOSIT" or "CARD_DEPOSIT" or "HOME_DELIVERY". The list of fields returned as true can vary depending on the destination country.

    * Start online, fund in store: For digital application wanting to fund the transactions in store, set the "fundInStore": true.

    * Telemarketing (US ONLY): It is regulatory requirement in the USA (only) to display a telemarketer notice to the start of every transaction, on every transfer, in every country and for every service option. The Telemarketer Notice must be displayed to the customer before quoting the transaction on the Quote API. Learn More

    * Fraud Warnings: It is regulatory requirement to show Fraud Warnings on every transfer, in every country and for every service option. The Fraud Warnings must be displayed to the customer before the final transaction summary and before the transactionID is executed to MoneyGram on the Commit API.
    1. Fraud Warnings US Only
    2. Fraud Warnings Global* Pre-disclosure: It is regulatory requirement to show pre-disclosure on every transfer, in every country and for every service option. Learn More




Code Examples

const axios = require('axios');
const { v4: uuidv4 } = require('uuid');

const updateTransaction = async () => {

    // Step 1: Read configuration values with upmost security
    const token = "your_access_token_from_oauth_response"
    // For production - api.moneygram.com & For test - sandboxapi.moneygram.com    
    const host = "sandboxapi.moneygram.com";
    const transactionId = "current_transaction_id";
    const url = 'https://' + host + '/disbursement/v1/transactions/' + transactionId;

    // Step 2: Create the PUT request headers & body
    const headers = {
        'Content-Type': 'application/json',
        'X-MG-ClientRequestId': uuidv4(), // New UUID for each request tracing
        'Authorization': 'Bearer ' + token,
    };
    const request = {
        agentPartnerId: "your_partner_id",
        targetAudience: "AGENT_FACING",
        userLanguage: "en-US",
        destinationCountryCode: "USA",
        destinationCountrySubdivisionCode: "US-MN",
        serviceOptionCode: "WILL_CALL",
        sendAmount: {
            currencyCode: "USD",
            value: 500
        },
        receiveCurrencyCode: "USD",
        initiator: {
            method: "batch",
            userId: "abc",
            userType: "consumer"
        },
        receiver: {
            name: {
                firstName: "firstName",
                middleName: "",
                lastName: "lastName",
                secondLastName: ""
            }
        }
    }

    try {
        // Step 3: Send the request and obtain the response
        axios.put(url, request, { headers })
            .then(function (response) {
                // Step 4: Parse the success response and process further
                // Verify readyForCommit is true, if yes, transaction is ready to commit
                console.log(JSON.stringify(response.data, null, 2))
            })
            .catch(function (error) {
                // Step 5: Parse the error response and handle the errors
                if (error.response) {
                    console.log('Response status:', error.response.status);
                    console.log('Response body:', error.response.data);
                } else {
                    // TODO: handle generic errors
                    console.error('Error:', error.message);
                }
            });
    } catch (error) {
        // TODO: handle exception
        console.error('Error:', error.message);
    }
};

updateTransaction();
import requests
import uuid
import json

def update_transaction():

    # Step 1: Read configuration values with upmost security
    token = "your_access_token_from_oauth_response"
    # For production - api.moneygram.com & For test - sandboxapi.moneygram.com    
    host = "sandboxapi.moneygram.com";
    transactionId = "current_transaction_id";
    url = 'https://' + host + '/disbursement/v1/transactions/'+ transactionId;

    # Step 2: Create the PUT request headers & body
    headers = {
        'Content-Type': 'application/json',
        'X-MG-ClientRequestId': str(uuid.uuid4()), # New UUID for each request tracing
        'Authorization': 'Bearer ' + token,
    }
    request = {
        'agentPartnerId': 'your_partner_id',
        'targetAudience': 'AGENT_FACING',
        'userLanguage': 'en-US',
        'destinationCountryCode': 'USA',
        'destinationCountrySubdivisionCode': 'US-MN',
        'serviceOptionCode': 'WILL_CALL',
        'sendAmount': {
            'currencyCode': 'USD',
            'value': 500
        },
        'receiveCurrencyCode': 'USD',
        'initiator': {
            'method': 'batch',
            'userId': 'abc',
            'userType': 'consumer'
        },
        'receiver': {
            'name': {
                'firstName': 'firstName',
                'middleName': '',
                'lastName': 'lastName',
                'secondLastName': ''
            }
        }
    }

    try:
        # Step 3: Send the request and obtain the response
        response = requests.put(url, json=request, headers=headers)

        # Step 4: Parse the success response and process further
        if response.status_code == 200:
            parsed_response = json.dumps(json.loads(response.text), indent=2)
            print(parsed_response)
        else:
            # Step 5: Parse the error response and handle the errors
            print("Request failed with status code:", response.status_code)
            print(json.dumps(json.loads(response.text), indent=2))

    except requests.exceptions.RequestException as e:
        # Print any error that occurred during the request
        # TODO: handle exception
        print("An error occurred:", e)

update_transaction()
package disbursement;

import javax.json.Json;
import javax.json.JsonObject;
import javax.json.JsonObjectBuilder;
import javax.json.JsonWriter;
import java.io.StringWriter;
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.util.UUID;

public class UpdateTransaction {

    public static void main(String[] args) {
        // Step 1: Read configuration values with upmost security
        String token = "your_access_token_from_oauth_response";

        // For production - api.moneygram.com & For test - sandboxapi.moneygram.com
        String host = "sandboxapi.moneygram.com";
        String transactionId = "current_transaction_id";
        String tokenEndpoint = "https://" + host + "/disbursement/v1/transactions/" + transactionId;

        // Step 2: Create the PUT request headers & body
        // Create a JSON object
        JsonObjectBuilder sendAmountBuilder = Json.createObjectBuilder()
                .add("currencyCode", "USD")
                .add("value", 500);
        JsonObjectBuilder initiatorBuilder = Json.createObjectBuilder()
                .add("method", "batch")
                .add("userId", "abc")
                .add("userType", "consumer");
        JsonObjectBuilder receiverBuilder = Json.createObjectBuilder()
                .add("name", Json.createObjectBuilder().add("firstName", "firstName").add("lastName", "lastName"));
        JsonObjectBuilder requestBuilder = Json.createObjectBuilder()
                .add("agentPartnerId", "your_partner_id")
                .add("targetAudience", "AGENT_FACING")
                .add("userLanguage", "en-US")
                .add("destinationCountryCode", "USA")
                .add("destinationCountrySubdivisionCode", "US-MN")
                .add("serviceOptionCode", "WILL_CALL")
                .add("sendAmount", sendAmountBuilder)
                .add("receiveCurrencyCode", "USD")
                .add("initiator", initiatorBuilder)
                .add("receiver", receiverBuilder);

        JsonObject jsonObject = requestBuilder.build();
        // Create a StringWriter to write the JSON string
        StringWriter stringWriter = new StringWriter();
        try (JsonWriter jsonWriter = Json.createWriter(stringWriter)) {
            jsonWriter.writeObject(jsonObject);
        }
        // Get the JSON string from the StringWriter
        String jsonString = stringWriter.toString();

        HttpClient httpClient = HttpClient.newHttpClient();
        HttpRequest request = HttpRequest.newBuilder()
                .uri(URI.create(tokenEndpoint))
                .PUT(HttpRequest.BodyPublishers.ofString(jsonString))
                .setHeader("Authorization", "Bearer " + token)
                .setHeader("X-MG-ClientRequestId", String.valueOf(UUID.randomUUID()))
                .build();

        try {
            // Step 3: Send the request and obtain the response
            HttpResponse<String> response = httpClient.send(request, HttpResponse.BodyHandlers.ofString());

            // Retrieve the status code and body from the response
            int statusCode = response.statusCode();

            // Step 4: Parse the success response and process further
            if (statusCode == 200) {
                String responseBody = response.body();
                System.out.println(responseBody);
            } else {
                // Step 5: Parse the error response and handle the errors
                String responseBody = response.body();
                System.out.println(responseBody);
            }
        } catch (Exception e) {
            e.printStackTrace();
            // TODO: handle exception
        }
    }
}



API Request & Response Examples

curl --request PUT \
     --url https://sandboxapi.moneygram.com/disbursement/v1/transactions/{transactionId} \
     --header 'X-MG-ClientRequestId: 4c79b06f-a2af-4859-82c8-28cbb0bf361b' \
     --header 'X-MG-SessionId: ******************************' \
     --header 'accept: application/json' \
     --header 'authorization: Bearer ***************************' \
     --header 'content-type: application/json' \
     --data '
{
  "targetAudience": "AGENT_FACING",
  "agentPartnerId": 30151518,
  "destinationCountryCode": "USA",
  "destinationCountrySubdivisionCode": "US-MN",
  "serviceOptionCode": "WILL_CALL",
  "sendAmount": {
    "value": 100,
    "currencyCode": "USD"
  },
  "receiveCurrencyCode": "USD",
  "initiator": {
    "method": "REAL_TIME",
    "userType": "CONSUMER"
  },
  "receiver": {
    "name": {
      "firstName": "Palu",
      "lastName": "Patel"
    },
    "address": {
      "line1": "100 Main St",
      "city": "Minneapolis",
      "countrySubdivisionCode": "US-MN",
      "countryCode": "USA"
    },
    "mobilePhone": {
      "number": "555-123-1234",
      "countryDialCode": 1
    },
    "personalDetails": {
      "dateOfBirth": "1998-10-01T00:00:00.000Z",
      "birthCity": "Minneapolis",
      "birthCountryCode": "USA"
    },
    "primaryIdentification": {
      "typeCode": "PAS",
      "id": "P12122345",
      "issueCountrySubdivisionCode": "IN-DL",
      "issueCountryCode": "IND",
      "issueCity": "New Delhi"
    },
    "secondaryIdentification": {
      "typeCode": "SSN",
      "id": 750455698,
      "issueCountrySubdivisionCode": "US-MN",
      "issueCountryCode": "USA",
      "issueCity": "Minneapolis"
    }
  }
}
'
{
  "readyForCommit": true,
  "transactionId": "**********-**-****-****-************",
  "referenceNumber": "********",
  "serviceOptionName": "10 Minute Service",
  "sendAmount": {
    "amount": {
      "value": 100,
      "currencyCode": "USD"
    },
    "fees": {
      "value": 3,
      "currencyCode": "USD"
    },
    "taxes": {
      "value": 0,
      "currencyCode": "USD"
    },
    "discountsApplied": {
      "totalDiscount": {
        "value": 0,
        "currencyCode": "USD"
      },
      "promotionDetails": []
    },
    "total": {
      "value": 103,
      "currencyCode": "USD"
    }
  },
  "receiveAmount": {
    "amount": {
      "value": 100,
      "currencyCode": "USD"
    },
    "fees": {
      "value": 0,
      "currencyCode": "USD"
    },
    "taxes": {
      "value": 0,
      "currencyCode": "USD"
    },
    "total": {
      "value": 100,
      "currencyCode": "USD"
    },
    "fxRate": 1,
    "fxRateEstimated": false
  }
}



Support APIs

To make your development easier, MoneyGram has provided a Reference Data APIs Module that can be queried to provide a list of supported fields, values and associated meta-data to use in your integration.

NameHTTP MethodEndpointsDescription
Retrieve Account Deposit FieldsGET/reference-data/v1/account-depositRetrieves required fields for account deposit delivery option
Retrieve CountriesGET/reference-data/v1/CountryRetrieves supported values and metadata for countries
Retrieve Countries ISO3GET/reference-data/v1 /countries/{iso3Code}Retrieves supported values and metadata for countries by ISO 3 Code
Retrieve CurrenciesGET/reference-data/v1/currenciesRetrieves supported values and metadata for currencies
Retrieve EnumerationsGET/reference-data/v1/enumerationsRetrieves enumerated values for fields
Retrieve Identification DocumentsGET/reference-data/v1/identification-DocumentsRetrieves required fields for identification documents
Retrieve Service OptionsGET/reference-data/v1/payout-optionsRetrieves supported values and metadata for Service Options



API Structure


Header Parameters

Name

Type

Required

/Optional

Description

X-MG-ClientRequestId

String

Required

Client Request ID that can be passed by the client application. Client request ID must be unique within a single session for unique requests. This attribute can be used for ensuring idempotent request processing for some APIs. MoneyGram recommends using a UUID for the value of this field.

X-MG-SessionId

String

Required

A GUID MoneyGram generates for correlating multiple calls within a transaction session

X-MG-ConsumerIPAddress

String

Optional

IP Address of the system initiating the session




Path Parameters

Field

Type

Required/

Optional

Description

transactionId

String

Required

Unique id of the transaction resource




Request Body Fields

Field

Type

Required

/Optional

Description

targetAudience

String

Required

Tailors MoneyGram’s error messages and field metadata to an in-store, digital or crypto customer. (Enumerated value)

*NOTE: For a full list of accepted target audience values. See the TARGET_AUDIENCE enumeration from theReference Data Enumerations endpoint *

agentPartnerId

String
Max length: 8

Required

Unique identifier for the agent or partner

userLanguage

String
Max length: 6

Optional

Language used by the user/operator

destinationCountryCode

String
Max Length: 3

Required

Transaction Destination Country (ISO alpha-3 code)

NOTE: For a full list of accepted destination Countries and supported destinationCountrySubdivisionCode seeReference Data API Module: Retrieve Countries ISO3 endpoint

destinationCountrySubdivisionCode

String
Max length: 6

Optional

Destination state/province is conditionally required when transacting to certain destination countries. (ISO alpha-3 code)

NOTE: For a full list of accepted destination countries and supported destination country subdivision codes seeReference Data API Module: Retrieve Countries ISO3 endpoint

serviceOptionCode

String
Max length: 21

required

Unique category code to identify the transaction method

NOTE: For a full list of accepted service option codes per destination country see theReference Data API Module: service-options endpoint

serviceOptionRoutingCode

String
Max length: 21

Required

Unique identifier of the individual banking, wallet, or card provider for the service option.

NOTE: For a full list of accepted service option codes per destination country see theReference Data API Module: service-options endpoint

sendAmount.value

String
Min length: 0
Max length: 14
Max Decimal Value: 3

Required

Transaction amount and currency excluding fees and exchange rate.

NOTE: For Crypto partners this is the fiat currency for the BUY/Sell or Ramp-on/Ramp-off

For a full list of transaction currency codes see theAPI Reference Data Module: currencies endpoint

sendAmount.currencyCode

String
Max length: 3

Required

Transaction send currency code for a transactBySendAmountRequest

receiveCurrencyCode

String
Max length: 3

Required

Receive Currency is needed when transacting to a destination country that supports more than one currency for a transactBySendAmountRequest (ISO alpha-3 code)

promotionCodes

String
Max length: 20

Optional

Unique code to apply a promotional discount

targetAccount

Dynamic

Optional

Dynamic field key/values

initiator.method

String

Required

Method of how this transaction is being initiated

initiator.userType

String

Required

User type of the initiator

initiator.userId

String

Optional

Unique Id of the initiator

receiver.name.firstName

String
Min length: 1
Max length: 20

Required

First Name

receiver.name.middleName

String
Min length: 1
Max length: 20

Optional

Middle Name (if applicable)

receiver.name.lastName

String
Min length: 1
Max length: 30

Required

Last Name

receiver.name.secondLastName

String
Min length: 1
Max length: 30

Optional

Second Last Name

receiver.address.line1

String
Min length: 5
Max length: 30

Required

Residence address line 1

receiver.address.line2

String
Min length: 1
Max length: 80

Optional

Residence address line 2 (if applicable)

receiver.address.line3

String
Min length: 1
Max length: 80

Optional

Residence address line 3 (if applicable)

receiver.address.city

String
Min length: 1
Max length: 20

Required

City of residence

receiver.address.countrySubdivisionCode

String
Length: 6

Optional

State/province of residence

NOTE: For a full list of accepted countries and supported destination country subdivision codes seeReference Data API Module: Retrieve Countries ISO3 endpoint

receiver.address.countryCode

String
Length: 3

Required

Country of residence (ISO Alpha-3 Code)

NOTE: For a full list of accepted countries and supported destination country subdivision codes seeReference Data API Module: Retrieve Countries ISO3 endpoint

receiver.address.postalCode

String
Min length: 2
Max length: 6

Optional

Postal/Zip code of residence

receiver.mobilePhone.number

String
Min length: 5
Max length: 14

Required

Phone number

receiver.mobilePhone.countryDialCode

String
Min length: 1
Max length: 5

Required

Country calling code (ISO alpha-3 code)

receiver.email

String
Min length: 1
Max length: 255

Optional

Email address

receiver.notificationPreferences.type

String

Optional

Consumer notification preference types (Enumerated Values)

receiver.notificationPreferences.channel

String

Optional

Delivery method of notification (Enumerated Values)

receiver.notificationPreferences.optIn

Boolean

Optional

Flag to declare customer opts-in to notification type and method

receiver.notificationLanguagePreference

String
Max length: 6

Optional

Language (ISO Alpha-3 code)

receiver.personalDetails.genderCode

String

Optional

Gender (Enumerated Values)

receiver.personalDetails.dateOfBirth

String
Length: 10

Required

Date of birth (YYYY-MM-DD)

receiver.personalDetails.birthCity

String
Min length: 1
Max length: 20

Optional

City of birth

receiver.personalDetails.birthCountryCode

String
Max Length: 3

Optional

Country of birth (ISO alpha-3 code)

NOTE: For a full list of accepted countries and supported destination country subdivision codes seeReference Data API Module: Retrieve Countries ISO3 endpoint

receiver.personalDetails.citizenshipCountryCode

String
Max Length: 3

Optional

Citizenship Country (ISO alpha-3 code)

NOTE: For a full list of accepted countries and supported destination country subdivision codes seeReference Data API Module: Retrieve Countries ISO3 endpoint

receiver.personalDetails.occupationCode

String

Optional

Occupation/Employment (Enumerated Values)

NOTE: For a full list of accepted occupation codessee Reference Data Enumerations endpoint

receiver.personalDetails.politicalExposedPerson

Boolean

Optional

Flag to declare a Politically Exposed Person (PEP)

receiver.primaryIdentification.typeCode

String

String
Max length: 3

Required

Type of identification document (Enumerated Values)

NOTE: For a full list of accepted Identification documents by country. seeReference Data Enumerations endpoint

receiver.primaryIdentification.id

string
Max length: 30

Required

Identification document number

receiver.primaryIdentification.issueCountrySubdivisionCode

String
Max length: 6

Optional

Issuing state/province of identification document.

NOTE: For a full list of accepted countries and supported destination country subdivision codes seeReference Data API Module: Retrieve Countries ISO3 endpoint

receiver.primaryIdentification.issueCountryCode

String
Max Length: 3

Required

Issuing country of identification document.

NOTE: For a full list of accepted countries and supported destination country subdivision codes seeReference Data API Module: Retrieve Countries ISO3 endpoint

receiver.primaryIdentification.expirationYear

String
Length: 4
Format: YYYY

Optional

Expiration year of identification document (YYYY)

receiver.primaryIdentification.expirationMonth

String
Length: 2
Format: MM

Optional

Expiration month of identification document (MM)

receiver.primaryIdentification.expirationDay

String
Length: 2
Format: DD

Optional

Expiration month of identification document (DD)

receiver.primaryIdentification.issueAuthority

String
Min length: 0
Max length: 30

Optional

Issuing authority of identification document

receiver.primaryIdentification.issueCity

String
Min length: 0
Max length: 20

Optional

Issuing city of identification document

receiver.primaryIdentification.issueYear

String
Length: 4
Format: YYYY

Optional

Issuing year of identification document (YYYY)

receiver.primaryIdentification.issueMonth

String
Length: 2
Format: MM

Optional

Issuing month of identification document (MM)

receiver.primaryIdentification.issueDay

String
Length: 2
Format: DD

Optional

Issuing day of identification document (DD)

receiver.secondaryIdentification.typeCode

String

String
Max length: 3

Optional

Type of identification document (Enumerated Values)

NOTE: For a full list of accepted Identification documents by country. seeReference Data Enumerations endpoint

receiver.secondaryIdentification.id

string
Max length: 30

Optional

Identification document number

receiver.secondaryIdentification.issueCountrySubdivisionCode

String
Max length: 6

Optional

Issuing state/province of identification document.

NOTE: For a full list of accepted countries and supported destination country subdivision codes seeReference Data API Module: Retrieve Countries ISO3 endpoint

receiver.secondaryIdentification.issueCountryCode

String
Max Length: 3

Optional

Issuing country of identification document.

NOTE: For a full list of accepted countries and supported destination country subdivision codes seeReference Data API Module: Retrieve Countries ISO3 endpoint

receiver.secondaryIdentification.expirationYear

String
Length: 4
Format: YYYY

Optional

Expiration year of identification document (YYYY)

receiver.secondaryIdentification.expirationMonth

String
Length: 2
Format: MM

optional

Expiration month of identification document (MM)

receiver.secondaryIdentification.expirationDay

String
Length: 2
Format: DD

Optional

Expiration month of identification document (DD)

receiver.secondaryIdentification.issueAuthority

String
Min length: 0
Max length: 30

Optional

Issuing authority of identification document

receiver.secondaryIdentification.issueCity

String
Min length: 0
Max length: 20

Optional

Issuing city of identification document

receiver.secondaryIdentification.issueYear

String
Length: 4
Format: YYYY

Optional

Issuing year of identification document (YYYY)

receiver.secondaryIdentification.issueMonth

String
Length: 4
Format: MM

Optional

Issuing month of identification document (MM)

receiver.secondaryIdentification.issueDay

String
Length: 4
Format: DD

Optional

Issuing day of identification document (DD)

receiver.additionalAddress.type

String

Optional

Type of Additional address (Enumerated Values)

receiver.additionalAddress.line1

String
Min length: 0
Max length: 30

Optional

Residence address line 1

receiver.additionalAddress.line2

String
Min length: 0
Max length: 30

Optional

Residence address line 2 (if applicable)

receiver.additionalAddress.line3

String
Min length: 0
Max length: 30

Optional

Residence address line 3 (if applicable)

receiver.additionalAddress.city

String
Min length: 0
Max length: 20

Required

City of residence

receiver.additionalAddress.countrySubdivisionCode

String
Max Length: 6

Optional

State/province of residence.

NOTE: For a full list of accepted countries and supported destination country subdivision codes seeReference Data API Module: Retrieve Countries ISO3 endpoint

receiver.additionalAddress.countryCode

String
Max length: 3

Required

Country of residence.

NOTE: For a full list of accepted countries and supported destination country subdivision codes seeReference Data API Module: Retrieve Countries ISO3 endpoint

receiver.additionalAddress.postalCode

String
Min length: 2
Max length: 6

Optional

Postal code/ZIP of residence

receiver.additionalFamilyNames.type

String

Optional

Type of family name (Enumerated Values)

receiver.additionalFamilyNames.firstName

String
Min length: 1
Max length: 20

Optional

First Name

receiver.additionalFamilyNames.middleName

String
Min length: 1
Max length: 20

Optional

Middle Name (if applicable)

receiver.additionalFamilyNames.lastName

String
Min length: 1
Max length: 30

Optional

Last Name

receiver.additionalFamilyNames.secondLastName

String
Min length: 1
Max length: 30

Optional

Second Last Name (if applicable)

receiver.additionalDetails

String
Min length: 1
Max length: 40

Optional

Dynamic field key/values

additionalDetails

Dynamic

Optional

Dynamic field key/values


Response Fields

Field

Type

Required

/Optional

Description

readyForCommit

Boolean

Optional

Indicates whether the transaction can proceed to commit

transactionId

String
Max length: 36

Optional

Unique identifier for the transaction resource

referenceNumber

String
Length: 8

Required

MoneyGram's reference number for the transaction

serviceOptionName

String
Max length: 40

Optional

Consumer facing name to identify the transaction method

sendAmount.amount

String
Max length: 14

Required

Transaction amount and currency excluding fees and exchange rate. Transaction Currency (ISO alpha-3 code)

For Crypto partners this is the fiat currency for the BUY/Sell or Ramp-on/Ramp-off

sendAmount.fees

String
Min length: 0
Max length: 14

Required

Fee Amount and Fee Currency applied to transaction (Fee currencyCode uses ISO alpha-3 code)

sendAmount.taxes

String
Min length: 0
Max length: 14

Optional

Tax Amount and Tax Currency applied to the Transaction by the the origin country (Tax currencyCode uses ISO alpha-3 code)

sendAmount.discountsApplied.totalDiscount

String
Min length: 0
Max length: 14

Optional

Transaction discount amount applied and currency type excluding fees and exchange rate. Transaction discount currencyCode (ISO alpha-3 code)

sendAmount.discountsApplied.promotionDetails

String
Min length: 0
Max length: 14

Optional

Additional Details about the applied promotion to the transaction. currencyCode (ISO alpha-3 code)

sendAmount.total

String
Max length: 14

Required

Transaction Total Amount and Transaction Total Currency including fees, taxes and discount. (Total currencyCode uses ISO alpha-3 code)

receiveAmount.amount

String
Max length: 14

Required

Transaction Received Amount and Transaction Receive currency. (Receive amount currencyCode uses ISO alpha-3 code)

receiveAmount.fees

String
Min length: 0
Max length: 14

Optional

Received Fee and Receive Currency applied to the transaction by the destination country. (Receve fee currencyCode uses ISO alpha-3 code)

receiveAmount.taxes

String
Min length: 0
Max length: 14

Optional

Tax Amount and Tax Currency applied to the Transaction by the the origin country. (Receive taxes currencyCode uses ISO alpha-3 code)

receiveAmount.total

String
Max length: 14

Required

Receive Amount Total and Receive Transaction Currency to be picked-up/deposited in destination country including fees, taxes and discount (Receive total currencyCode uses ISO alpha-3 code)

receiveAmount.fxRate

Number
String
Min length: 0
Max length: 14

Required

Fx Rate applied to transaction

sendAmount.fxRateEstimated

Boolean

Optional

Indicates whether the Fx is “estimated” and amount, taxes and total cannot be guaranteed. The word “estimated” must appear before receiveAmount.amount, receiveAmount.taxes and receiveAmount.total only when true.