curl --request PUT \
--url https://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'account: <account>' \
--data '
{
"name": "Peter Parker",
"month": 12,
"year": 2030
}
'import requests
url = "https://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId}"
payload = {
"name": "Peter Parker",
"month": 12,
"year": 2030
}
headers = {
"account": "<account>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {
account: '<account>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({name: 'Peter Parker', month: 12, year: 2030})
};
fetch('https://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId}', 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://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'Peter Parker',
'month' => 12,
'year' => 2030
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"account: <account>"
],
]);
$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://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId}"
payload := strings.NewReader("{\n \"name\": \"Peter Parker\",\n \"month\": 12,\n \"year\": 2030\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("account", "<account>")
req.Header.Add("Authorization", "Bearer <token>")
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.put("https://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId}")
.header("account", "<account>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Peter Parker\",\n \"month\": 12,\n \"year\": 2030\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["account"] = '<account>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"Peter Parker\",\n \"month\": 12,\n \"year\": 2030\n}"
response = http.request(request)
puts response.read_body{
"mensagem": "Cartão atualizado com sucesso.",
"erro": false,
"mensagenserro": [],
"codigoretorno": 200,
"id": "00000000-0000-0000-0000-000000000000",
"data": {
"id": "9b2f5c8e-3a1d-4f7b-8c6e-2d9a1b4c5e6f",
"card_token": "9b2f5c8e-3a1d-4f7b-8c6e-2d9a1b4c5e6f",
"first_six_digits": "542501",
"last_four_digits": "7793",
"brand": "mastercard",
"holder_name": "Peter Parker",
"exp_month": 12,
"exp_year": 2030,
"type": "credit",
"status": "active",
"tokenization_status": "tokenized",
"created_at": "2026-04-03T20:54:58-03:00",
"updated_at": "2026-04-04T12:25:32-03:00"
}
}{
"mensagem": "Unauthenticated.",
"erro": true,
"mensagenserro": [],
"codigoretorno": 401,
"id": "00000000-0000-0000-0000-000000000000",
"data": []
}{
"mensagem": "The charge code does not match any charge",
"erro": true,
"mensagenserro": [],
"codigoretorno": 404,
"id": "00000000-0000-0000-0000-000000000000",
"data": []
}{
"message": "The given data was invalid.",
"errors": {
"client.email": [
"O campo client.email é obrigatório."
]
}
}{
"mensagem": "Um erro aconteceu.",
"erro": true,
"mensagenserro": [
"Erro interno. Tente novamente mais tarde."
],
"codigoretorno": 500,
"id": "00000000-0000-0000-0000-000000000000",
"data": []
}Atualizar Cartão
Atualiza os dados editáveis de um cartão. Apenas name, type, flag e a validade (month + year, enviados juntos) podem ser alterados. O número e o código de segurança são imutáveis. Ao alterar a validade, a tokenização do cartão é reiniciada e o resultado é enviado por webhook (card.token_created / card.token_failed). Um evento card.updated é emitido a cada atualização. Requer o header account com o código da conta.
curl --request PUT \
--url https://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'account: <account>' \
--data '
{
"name": "Peter Parker",
"month": 12,
"year": 2030
}
'import requests
url = "https://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId}"
payload = {
"name": "Peter Parker",
"month": 12,
"year": 2030
}
headers = {
"account": "<account>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {
account: '<account>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({name: 'Peter Parker', month: 12, year: 2030})
};
fetch('https://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId}', 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://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'Peter Parker',
'month' => 12,
'year' => 2030
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"account: <account>"
],
]);
$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://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId}"
payload := strings.NewReader("{\n \"name\": \"Peter Parker\",\n \"month\": 12,\n \"year\": 2030\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("account", "<account>")
req.Header.Add("Authorization", "Bearer <token>")
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.put("https://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId}")
.header("account", "<account>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Peter Parker\",\n \"month\": 12,\n \"year\": 2030\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.4seletpay.com.br/api/v1/clients/{clientCode}/cards/{cardId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["account"] = '<account>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"Peter Parker\",\n \"month\": 12,\n \"year\": 2030\n}"
response = http.request(request)
puts response.read_body{
"mensagem": "Cartão atualizado com sucesso.",
"erro": false,
"mensagenserro": [],
"codigoretorno": 200,
"id": "00000000-0000-0000-0000-000000000000",
"data": {
"id": "9b2f5c8e-3a1d-4f7b-8c6e-2d9a1b4c5e6f",
"card_token": "9b2f5c8e-3a1d-4f7b-8c6e-2d9a1b4c5e6f",
"first_six_digits": "542501",
"last_four_digits": "7793",
"brand": "mastercard",
"holder_name": "Peter Parker",
"exp_month": 12,
"exp_year": 2030,
"type": "credit",
"status": "active",
"tokenization_status": "tokenized",
"created_at": "2026-04-03T20:54:58-03:00",
"updated_at": "2026-04-04T12:25:32-03:00"
}
}{
"mensagem": "Unauthenticated.",
"erro": true,
"mensagenserro": [],
"codigoretorno": 401,
"id": "00000000-0000-0000-0000-000000000000",
"data": []
}{
"mensagem": "The charge code does not match any charge",
"erro": true,
"mensagenserro": [],
"codigoretorno": 404,
"id": "00000000-0000-0000-0000-000000000000",
"data": []
}{
"message": "The given data was invalid.",
"errors": {
"client.email": [
"O campo client.email é obrigatório."
]
}
}{
"mensagem": "Um erro aconteceu.",
"erro": true,
"mensagenserro": [
"Erro interno. Tente novamente mais tarde."
],
"codigoretorno": 500,
"id": "00000000-0000-0000-0000-000000000000",
"data": []
}account com o código da conta. Apenas name, type, flag e a validade (month + year, enviados juntos) podem ser alterados.card.updated. Ao alterar a validade, a tokenização é reiniciada e o resultado é enviado por webhook (card.token_created / card.token_failed).Authorizations
Token JWT obtido via POST /v1/login. Envie no header Authorization: Bearer <token>.
Headers
Código da conta à qual a operação se aplica
"acc_abc123xyz"
Path Parameters
Código único do cliente dono do cartão
"cli_abc123"
UUID do cartão
"9b2f5c8e-3a1d-4f7b-8c6e-2d9a1b4c5e6f"
Body
Todos os campos são opcionais. O número e o código de segurança são imutáveis. Ao enviar a validade, month e year devem vir juntos.
Nome do portador impresso no cartão
255"Peter Parker"
Tipo do cartão
credit, debit "credit"
Bandeira do cartão
visa, mastercard, elo, amex "mastercard"
Mês de validade (obrigatório junto com year)
1 <= x <= 1212
Ano de validade (obrigatório junto com month)
2030
Response
Cartão atualizado com sucesso
