v1

latestOpenAPI 3.0.12026-07-264182324.3 KB
Orders

Retrieves or regenerates the <code>embedded_js_url</code> for one or more orders. The endpoint supports requests for a specific order (using <code>pnm_order_identifier</code> or <code>site_order_identifier</code>) or for multiple orders associated with a consumer (using <code>pnm_customer_identifier</code> or <code>site_customer_identifier</code>).</br></br> The <code>embedded_js_url</code> is required to invoke the Embedded Form. This URL expires 30 minutes after order creation, whether the order is created via bulk file upload or through the /create_order endpoint. Before an agent can invoke the Embedded Form, the <code>embedded_js_url</code> must be regenerated if it has expired.</br></br>When regenerating the <code>embedded_js_url</code> for all orders associated with a customer, pagination parameters can be used to control the response size. The <code>limit</code> parameter specifies the maximum number of orders (up to <code>5</code>) to return per request (default is <code>2</code>). Use the <code>offset</code> parameter to specify the number of orders to skip in the response (default is <code>0</code>). </br></br>To regenerate the <code>embedded_js_url</code> for all matching orders regardless of expiration status, set the <code>force</code> parameter to <code>true</code>. If <code>force</code> is set to <code>false</code> or is not provided, the <code>embedded_js_url</code> is regenerated only for orders where the existing URL has expired.

post/refresh_embedded_js_urls

Request body

OR
OR
OR

Example request

{
  "pnm_order_identifier": "84338052224"
}

Response

Successful Operation

pnm_order_identifierstring

The PayNearMe-created ID for the order.

site_order_identifierstring

An arbitrary string that the client uses to refer to an order.

pnm_customer_identifierstring

A PayNearMe-assigned ID for the customer.

site_customer_identifierstring

A client-assigned ID for the customer.

urlstring

A dynamic JavaScript URL that is used to invoke the PayNearMe Embedded Form.

Example response

{
  "pnm_order_identifier": "83517813169",
  "site_order_identifier": "2142455462",
  "pnm_customer_identifier": "U9745174469",
  "site_customer_identifier": "12345678",
  "url": "https://www.paynearme-sandbox.com/api/embedded/jfcEO4vPld85QZfF9ke_2A/script.js"
}