const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://core.prod.gnosispay.com/user-api/cards/{cardId}/limit', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://core.prod.gnosispay.com/user-api/cards/{cardId}/limit \
--header 'Authorization: Bearer <token>'import requests
url = "https://core.prod.gnosispay.com/user-api/cards/{cardId}/limit"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://core.prod.gnosispay.com/user-api/cards/{cardId}/limit"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://core.prod.gnosispay.com/user-api/cards/{cardId}/limit")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://core.prod.gnosispay.com/user-api/cards/{cardId}/limit")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"amount": 123,
"currency": "<string>",
"decimals": 123,
"syncStatus": "pending",
"updatedAt": "2023-11-07T05:31:56Z",
"spentToday": 123,
"remaining": 123
}{
"kind": "validation",
"success": false,
"error": {
"name": "ValidationError",
"message": "<string>"
}
}{
"success": false,
"error": "<string>"
}{
"success": false,
"error": "<string>"
}{
"success": false,
"error": "<string>"
}{
"success": false,
"error": "<string>"
}Get Card Daily Spending Limit
Returns the daily spending limit configured on a card. currency is the
card’s native currency, and amount is in that currency’s smallest unit
(minor units) — divide by 10^decimals to get the major-unit value. The
card must belong to the authenticated user. Once synced, this is a
cumulative spending limit, not a per-transaction cap: an authorization
that meets or exceeds the limit can be approved, after which subsequent
eligible authorizations are declined.
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://core.prod.gnosispay.com/user-api/cards/{cardId}/limit', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://core.prod.gnosispay.com/user-api/cards/{cardId}/limit \
--header 'Authorization: Bearer <token>'import requests
url = "https://core.prod.gnosispay.com/user-api/cards/{cardId}/limit"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://core.prod.gnosispay.com/user-api/cards/{cardId}/limit"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://core.prod.gnosispay.com/user-api/cards/{cardId}/limit")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://core.prod.gnosispay.com/user-api/cards/{cardId}/limit")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"amount": 123,
"currency": "<string>",
"decimals": 123,
"syncStatus": "pending",
"updatedAt": "2023-11-07T05:31:56Z",
"spentToday": 123,
"remaining": 123
}{
"kind": "validation",
"success": false,
"error": {
"name": "ValidationError",
"message": "<string>"
}
}{
"success": false,
"error": "<string>"
}{
"success": false,
"error": "<string>"
}{
"success": false,
"error": "<string>"
}{
"success": false,
"error": "<string>"
}Path Parameters
Response
The request has succeeded.
Daily limit in the currency's smallest unit (minor units). Divide by 10^decimals to get the major-unit value.
ISO-4217 currency code — the card's native currency.
Number of decimal places for this currency.
Replication state of the limit. 'pending' immediately after an update, 'synced' once the change has been applied downstream, 'failed' if the change could not be applied after retries.
pending, synced, failed Last time this limit was modified.
Amount spent today against this card's limit, in the currency's smallest unit (minor units). Resets at the start of each calendar day.
Remaining headroom today, in the currency's smallest unit. Equals max(0, amount - spentToday).