Skip to main content
GET
/
payment-links
/
{paymentLinkId}
Get payment link
curl --request GET \
  --url https://apiv2.example.com/payment-links/{paymentLinkId} \
  --header 'X-Api-Key: <api-key>'
import requests

url = "https://apiv2.example.com/payment-links/{paymentLinkId}"

headers = {"X-Api-Key": "<api-key>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {'X-Api-Key': '<api-key>'}};

fetch('https://apiv2.example.com/payment-links/{paymentLinkId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://apiv2.example.com/payment-links/{paymentLinkId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Api-Key: <api-key>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://apiv2.example.com/payment-links/{paymentLinkId}"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("X-Api-Key", "<api-key>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://apiv2.example.com/payment-links/{paymentLinkId}")
.header("X-Api-Key", "<api-key>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://apiv2.example.com/payment-links/{paymentLinkId}")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["X-Api-Key"] = '<api-key>'

response = http.request(request)
puts response.read_body
{
  "paymentLinkId": "j47ac10b-58cc-4372-a567-0e02b2c3d479",
  "hostedUrl": "https://checkout.yourapp.com/pay/j47ac10b-58cc-4372-a567-0e02b2c3d479",
  "createdAt": "2024-01-15T10:00:00Z",
  "updatedAt": "2024-01-15T10:00:00Z",
  "orderId": "44567801-a504-4f09-8089-31ea78bc239b",
  "customerId": "a1b2c3d4-e5f6-4a5b-8c9d-0e1f2a3b4c5d",
  "paymentProvider": "STRIPE",
  "paymentProfileId": "6ba7b810-9dad-11d1-80b4-00c04fd430c8",
  "description": "Pay your monthly subscription",
  "paymentIntentId": "64870b5c-fb61-4c9a-955a-e148e0826c20",
  "completedAt": "2024-01-15T14:30:00Z",
  "metadata": {}
}
{
"message": "<string>",
"code": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"property": "<string>",
"suggestion": "<string>"
}
],
"hint": "<string>"
}
{
"message": "<string>",
"code": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"property": "<string>",
"suggestion": "<string>"
}
],
"hint": "<string>"
}
{
"message": "<string>",
"code": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"property": "<string>",
"suggestion": "<string>"
}
],
"hint": "<string>"
}
{
"message": "<string>",
"code": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"property": "<string>",
"suggestion": "<string>"
}
],
"hint": "<string>"
}
{
"message": "<string>",
"code": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"property": "<string>",
"suggestion": "<string>"
}
],
"hint": "<string>"
}

Authorizations

X-Api-Key
string
header
required

An API key that grants access to the Connect API. You can create and manage API keys in the portal.

Path Parameters

The unique identifier for the payment link.

Response

Payment link details.

A hosted payment link created from a payment intent that can be shared with customers.

Unique identifier for the payment link.

Example:

"j47ac10b-58cc-4372-a567-0e02b2c3d479"

hostedUrl
string<uri>
required

The URL where customers can complete their payment.

Example:

"https://checkout.yourapp.com/pay/j47ac10b-58cc-4372-a567-0e02b2c3d479"

status
enum<string>
required

Current status of a payment link.

Available options:
ACTIVE,
EXPIRED,
COMPLETED,
CANCELED,
FAILED
createdAt
string<date-time>
required

When the payment link was created.

Example:

"2024-01-15T10:00:00Z"

updatedAt
string<date-time>
required

When the payment link was last updated.

Example:

"2024-01-15T10:00:00Z"

orderId
string

The order this payment link collects payment for.

Example:

"44567801-a504-4f09-8089-31ea78bc239b"

customerId
string

The customer this payment link collects payment from.

Example:

"a1b2c3d4-e5f6-4a5b-8c9d-0e1f2a3b4c5d"

paymentProvider
enum<string>

Payment service provider that processes the transaction.

Available options:
STRIPE,
BILLOGRAM
Example:

"STRIPE"

paymentProfileId
string

The saved payment method pre-selected for the customer, if any.

Example:

"6ba7b810-9dad-11d1-80b4-00c04fd430c8"

description
string

Optional description displayed on the payment page.

Example:

"Pay your monthly subscription"

paymentIntentId
string

The payment intent that collected the payment, available once the link has been paid.

Example:

"64870b5c-fb61-4c9a-955a-e148e0826c20"

completedAt
string<date-time>

When the payment was completed, if the link has been paid.

Example:

"2024-01-15T14:30:00Z"

metadata
object

A set of key-value pairs that can be attached to an object for storing additional information in a semi-structured format.