Get Order Intent Credentials
curl --request POST \
--url https://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <x-api-key>' \
--data '
{
"merchant": {
"name": "<string>",
"url": "<string>",
"countryCode": "<string>"
},
"products": [
{
"name": "<string>",
"price": 1,
"quantity": 4503599627370496
}
]
}
'import requests
url = "https://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials"
payload = {
"merchant": {
"name": "<string>",
"url": "<string>",
"countryCode": "<string>"
},
"products": [
{
"name": "<string>",
"price": 1,
"quantity": 4503599627370496
}
]
}
headers = {
"X-API-KEY": "<x-api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-KEY': '<x-api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
merchant: {name: '<string>', url: '<string>', countryCode: '<string>'},
products: [{name: '<string>', price: 1, quantity: 4503599627370496}]
})
};
fetch('https://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials', 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://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'merchant' => [
'name' => '<string>',
'url' => '<string>',
'countryCode' => '<string>'
],
'products' => [
[
'name' => '<string>',
'price' => 1,
'quantity' => 4503599627370496
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-KEY: <x-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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials"
payload := strings.NewReader("{\n \"merchant\": {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"countryCode\": \"<string>\"\n },\n \"products\": [\n {\n \"name\": \"<string>\",\n \"price\": 1,\n \"quantity\": 4503599627370496\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-KEY", "<x-api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials")
.header("X-API-KEY", "<x-api-key>")
.header("Content-Type", "application/json")
.body("{\n \"merchant\": {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"countryCode\": \"<string>\"\n },\n \"products\": [\n {\n \"name\": \"<string>\",\n \"price\": 1,\n \"quantity\": 4503599627370496\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-KEY"] = '<x-api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"merchant\": {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"countryCode\": \"<string>\"\n },\n \"products\": [\n {\n \"name\": \"<string>\",\n \"price\": 1,\n \"quantity\": 4503599627370496\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"card": {
"number": "<string>",
"expirationMonth": "<string>",
"expirationYear": "<string>",
"cvc": "<string>"
},
"expiresAt": "<string>"
}Agent Cards
Get Agent Card Credentials
Get credentials for an order intent.
API scope required: order-intents.credentials
POST
/
unstable
/
order-intents
/
{orderIntentId}
/
credentials
Get Order Intent Credentials
curl --request POST \
--url https://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <x-api-key>' \
--data '
{
"merchant": {
"name": "<string>",
"url": "<string>",
"countryCode": "<string>"
},
"products": [
{
"name": "<string>",
"price": 1,
"quantity": 4503599627370496
}
]
}
'import requests
url = "https://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials"
payload = {
"merchant": {
"name": "<string>",
"url": "<string>",
"countryCode": "<string>"
},
"products": [
{
"name": "<string>",
"price": 1,
"quantity": 4503599627370496
}
]
}
headers = {
"X-API-KEY": "<x-api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-KEY': '<x-api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
merchant: {name: '<string>', url: '<string>', countryCode: '<string>'},
products: [{name: '<string>', price: 1, quantity: 4503599627370496}]
})
};
fetch('https://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials', 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://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'merchant' => [
'name' => '<string>',
'url' => '<string>',
'countryCode' => '<string>'
],
'products' => [
[
'name' => '<string>',
'price' => 1,
'quantity' => 4503599627370496
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-KEY: <x-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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials"
payload := strings.NewReader("{\n \"merchant\": {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"countryCode\": \"<string>\"\n },\n \"products\": [\n {\n \"name\": \"<string>\",\n \"price\": 1,\n \"quantity\": 4503599627370496\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-KEY", "<x-api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials")
.header("X-API-KEY", "<x-api-key>")
.header("Content-Type", "application/json")
.body("{\n \"merchant\": {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"countryCode\": \"<string>\"\n },\n \"products\": [\n {\n \"name\": \"<string>\",\n \"price\": 1,\n \"quantity\": 4503599627370496\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://staging.crossmint.com/api/unstable/order-intents/{orderIntentId}/credentials")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-KEY"] = '<x-api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"merchant\": {\n \"name\": \"<string>\",\n \"url\": \"<string>\",\n \"countryCode\": \"<string>\"\n },\n \"products\": [\n {\n \"name\": \"<string>\",\n \"price\": 1,\n \"quantity\": 4503599627370496\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"card": {
"number": "<string>",
"expirationMonth": "<string>",
"expirationYear": "<string>",
"cvc": "<string>"
},
"expiresAt": "<string>"
}Headers
API key required for authentication
Path Parameters
Body
application/json
Was this page helpful?
⌘I

