const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({answer: '<string>'})
};
fetch('https://core.prod.gnosispay.com/partner-api/v1/cards/details', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://core.prod.gnosispay.com/partner-api/v1/cards/details \
--header 'Content-Type: application/json' \
--data '
{
"answer": "<string>"
}
'import requests
url = "https://core.prod.gnosispay.com/partner-api/v1/cards/details"
payload = { "answer": "<string>" }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://core.prod.gnosispay.com/partner-api/v1/cards/details"
payload := strings.NewReader("{\n \"answer\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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://core.prod.gnosispay.com/partner-api/v1/cards/details")
.header("Content-Type", "application/json")
.body("{\n \"answer\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://core.prod.gnosispay.com/partner-api/v1/cards/details")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"answer\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"data": "<string>"
}{
"code": 123,
"message": "<string>",
"reason": "<string>"
}Read the card details
Returns the PAN, the CVV and the expiration date encrypted to the key of
the application, after the account owner signed a
cards.read_details.v1 challenge. The application calls this route
directly; your backend never sees the request or the reply. The route
takes no access token and allows any CORS origin.
Returns 401 with reason INVALID_CHALLENGE when any check of the
answer, the challenge or the signature fails, or when the challenge was
already used or expired. The reply does not say which check failed.
Returns 422 with reason CARD_STATE_NOT_ALLOWED when the card no longer
allows the action, 502 when the card processor failed after the challenge
was used (ask for a new challenge), and 503 when the request can be
retried with the same challenge.
const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({answer: '<string>'})
};
fetch('https://core.prod.gnosispay.com/partner-api/v1/cards/details', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://core.prod.gnosispay.com/partner-api/v1/cards/details \
--header 'Content-Type: application/json' \
--data '
{
"answer": "<string>"
}
'import requests
url = "https://core.prod.gnosispay.com/partner-api/v1/cards/details"
payload = { "answer": "<string>" }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://core.prod.gnosispay.com/partner-api/v1/cards/details"
payload := strings.NewReader("{\n \"answer\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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://core.prod.gnosispay.com/partner-api/v1/cards/details")
.header("Content-Type", "application/json")
.body("{\n \"answer\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://core.prod.gnosispay.com/partner-api/v1/cards/details")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"answer\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"data": "<string>"
}{
"code": 123,
"message": "<string>",
"reason": "<string>"
}