curl --request POST \
--url https://api.ephra.io/v1/checkouts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"productId": "clx8a2h4k0001qz0a1b2c3d4e",
"checkoutName": "Checkout Black Friday"
}
'import requests
url = "https://api.ephra.io/v1/checkouts"
payload = {
"productId": "clx8a2h4k0001qz0a1b2c3d4e",
"checkoutName": "Checkout Black Friday"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({productId: 'clx8a2h4k0001qz0a1b2c3d4e', checkoutName: 'Checkout Black Friday'})
};
fetch('https://api.ephra.io/v1/checkouts', 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://api.ephra.io/v1/checkouts",
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([
'productId' => 'clx8a2h4k0001qz0a1b2c3d4e',
'checkoutName' => 'Checkout Black Friday'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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://api.ephra.io/v1/checkouts"
payload := strings.NewReader("{\n \"productId\": \"clx8a2h4k0001qz0a1b2c3d4e\",\n \"checkoutName\": \"Checkout Black Friday\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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.post("https://api.ephra.io/v1/checkouts")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"productId\": \"clx8a2h4k0001qz0a1b2c3d4e\",\n \"checkoutName\": \"Checkout Black Friday\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ephra.io/v1/checkouts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"productId\": \"clx8a2h4k0001qz0a1b2c3d4e\",\n \"checkoutName\": \"Checkout Black Friday\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"id": "clxb7n3q10007qz0a5t6u7v8w",
"version": "v2",
"checkoutName": "Checkout Black Friday",
"productId": "clx8a2h4k0001qz0a1b2c3d4e",
"active": true,
"slug": "mk041zu",
"isDefault": null,
"model": null,
"billingType": "one_time",
"acceptMethod": [
"pix",
"credit_card"
],
"preferredPaymentMethod": null,
"maxInstallments": 12,
"defaultOfferId": null,
"preDefinedInstallmentEnabled": true,
"preDefinedInstallmentValue": 12,
"collectBuyerAddress": false,
"askBuyerInstagram": false,
"enableAddressAutofill": true,
"collectInstagram": false,
"upsellEnabled": false,
"upsellRedirectUrl": null,
"imageUrl": null,
"marketLanguage": null,
"invoiceName": null,
"billetExpireTime": null,
"allowedDoubleCard": false,
"allowedCardPix": false,
"allowedSmartInstallment": false,
"createdAt": "2026-09-12T09:09:16.365Z",
"updatedAt": "2026-09-12T09:09:16.365Z"
}
}{
"success": false,
"message": "Não foi possível concluir: uma regra de negócio recusou os dados enviados."
}{
"success": false,
"message": "Token inválido ou expirado"
}{
"success": false,
"message": "Produto não encontrado"
}{
"success": false,
"message": "name: Nome é obrigatório"
}{
"success": false,
"message": "Muitas requisições. Tente novamente em breve."
}{
"success": false,
"message": "Erro interno do servidor"
}Criar checkout
Cria uma página de checkout para um produto da empresa autenticada, já com os padrões de layout, campos e meios de pagamento. A geração do construtor sai do próprio produto — produtos migrados ganham um checkout v2, os demais um v1 —, então o vendedor pode criar variações para teste A/B sem escolher tabela nenhuma. Em productId vai o id de um produto seu, o mesmo que GET /v1/products devolve e que o exemplo de POST /v1/products cria — troque o do exemplo pelo seu. Responde 404 quando o produto não existe ou é de outra empresa.
curl --request POST \
--url https://api.ephra.io/v1/checkouts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"productId": "clx8a2h4k0001qz0a1b2c3d4e",
"checkoutName": "Checkout Black Friday"
}
'import requests
url = "https://api.ephra.io/v1/checkouts"
payload = {
"productId": "clx8a2h4k0001qz0a1b2c3d4e",
"checkoutName": "Checkout Black Friday"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({productId: 'clx8a2h4k0001qz0a1b2c3d4e', checkoutName: 'Checkout Black Friday'})
};
fetch('https://api.ephra.io/v1/checkouts', 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://api.ephra.io/v1/checkouts",
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([
'productId' => 'clx8a2h4k0001qz0a1b2c3d4e',
'checkoutName' => 'Checkout Black Friday'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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://api.ephra.io/v1/checkouts"
payload := strings.NewReader("{\n \"productId\": \"clx8a2h4k0001qz0a1b2c3d4e\",\n \"checkoutName\": \"Checkout Black Friday\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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.post("https://api.ephra.io/v1/checkouts")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"productId\": \"clx8a2h4k0001qz0a1b2c3d4e\",\n \"checkoutName\": \"Checkout Black Friday\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ephra.io/v1/checkouts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"productId\": \"clx8a2h4k0001qz0a1b2c3d4e\",\n \"checkoutName\": \"Checkout Black Friday\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"id": "clxb7n3q10007qz0a5t6u7v8w",
"version": "v2",
"checkoutName": "Checkout Black Friday",
"productId": "clx8a2h4k0001qz0a1b2c3d4e",
"active": true,
"slug": "mk041zu",
"isDefault": null,
"model": null,
"billingType": "one_time",
"acceptMethod": [
"pix",
"credit_card"
],
"preferredPaymentMethod": null,
"maxInstallments": 12,
"defaultOfferId": null,
"preDefinedInstallmentEnabled": true,
"preDefinedInstallmentValue": 12,
"collectBuyerAddress": false,
"askBuyerInstagram": false,
"enableAddressAutofill": true,
"collectInstagram": false,
"upsellEnabled": false,
"upsellRedirectUrl": null,
"imageUrl": null,
"marketLanguage": null,
"invoiceName": null,
"billetExpireTime": null,
"allowedDoubleCard": false,
"allowedCardPix": false,
"allowedSmartInstallment": false,
"createdAt": "2026-09-12T09:09:16.365Z",
"updatedAt": "2026-09-12T09:09:16.365Z"
}
}{
"success": false,
"message": "Não foi possível concluir: uma regra de negócio recusou os dados enviados."
}{
"success": false,
"message": "Token inválido ou expirado"
}{
"success": false,
"message": "Produto não encontrado"
}{
"success": false,
"message": "name: Nome é obrigatório"
}{
"success": false,
"message": "Muitas requisições. Tente novamente em breve."
}{
"success": false,
"message": "Erro interno do servidor"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Produto que vai receber o novo checkout, de GET /v1/products.
^[cC][^\s-]{8,}$Nome interno do checkout, para o vendedor diferenciar variações em teste A/B.
1 - 120Oferta a vincular ao checkout no momento da criação. Aceito apenas em produtos da geração v1.
x > 0