Public checkout reads
Read link metadata and checkout status without exposing merchant credentials.
Payment link status
Public payment link status accepts the returned short_id in the path. Its example includes status, transaction_id, usage counters and is_active. No merchant HMAC or dashboard authorization is documented.
Link details
Checkout link details returns the documented narrow metadata: ID, short ID, title, amount, currency and link status. Customers should still use the checkout_url supplied when creating the intent.
Keep credentials private
Do not attach merchant secrets to these customer-facing reads. GET requests have no body. Numeric rate limits and a full public-field schema are not established by the supplied contract.
Keep backend records authoritative
Use callbacks for asynchronous transaction updates and signed transaction status for recovery. Do not mark an order paid from a browser redirect alone.
Request example
Choose Node.js, Python, PHP, Ruby, Java or cURL. Run signed requests on your backend. PHP, Ruby and Java include signing directly. Java requires JDK 17 or newer.
This public read does not require merchant credentials.
const short_id = process.env.ZYTEPE_SHORT_ID;
if (!short_id) throw new Error('Set ZYTEPE_SHORT_ID to the returned identifier');
const path = `/api/v1/collections/intents/${encodeURIComponent(short_id)}/status`;
const query = '';
const body = ''; // GET requests have no body
const headers = {};
const url = 'https://api.zytepe.com' + path + (query ? '?' + query : '');
const response = await fetch(url, { method: 'GET', headers });
if (!response.ok) throw new Error('Request failed: HTTP ' + response.status);
const result = await response.json();
// Store the returned identifiers securely. Do not log customer data.import json, os
from urllib.parse import quote
from urllib.request import Request, urlopen
short_id = os.environ['ZYTEPE_SHORT_ID']
path = f'/api/v1/collections/intents/{quote(short_id, safe="")}/status'
query = ''
body = '' # GET requests have no body
headers = {}
url = 'https://api.zytepe.com' + path + ('?' + query if query else '')
request = Request(url, method='GET', headers=headers)
with urlopen(request, timeout=30) as response:
result = json.load(response)
# Store identifiers securely; handle HTTPError/URLError in your application.<?php
// PHP 8+ with the cURL extension. Run on your server.
function envRequired(string $name): string {
$value = getenv($name);
if ($value === false || $value === '') throw new RuntimeException('Set ' . $name);
return $value;
}
$path = '/api/v1/collections/intents/{short_id}/status';
$path = str_replace('{short_id}', rawurlencode(envRequired('ZYTEPE_SHORT_ID')), $path);
$query = '';
$body = ''; // No body for GET
$headers = [];
$url = 'https://api.zytepe.com' . $path . ($query !== '' ? '?' . $query : '');
$ch = curl_init($url);
curl_setopt_array($ch, [CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_RETURNTRANSFER => true, CURLOPT_HTTPHEADER => $headers,
CURLOPT_TIMEOUT => 30]);
$response = curl_exec($ch);
if ($response === false) throw new RuntimeException(curl_error($ch));
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status >= 400) throw new RuntimeException('HTTP ' . $status);
$result = json_decode($response, true, 512, JSON_THROW_ON_ERROR);
// Store returned identifiers securely. Recover uncertain payments before retrying.require 'net/http'
require 'uri'
require 'json'
path = '/api/v1/collections/intents/{short_id}/status'
path = path.gsub('{short_id}', URI.encode_www_form_component(ENV.fetch('ZYTEPE_SHORT_ID')).gsub('+', '%20'))
query = ''
body = '' # No body for GET
headers = {}
uri = URI('https://api.zytepe.com' + path + (query.empty? ? '' : '?' + query))
request = Net::HTTP::Get.new(uri, headers)
response = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true, open_timeout: 10, read_timeout: 30) do |http|
http.request(request)
end
raise 'HTTP ' + response.code unless response.is_a?(Net::HTTPSuccess)
result = JSON.parse(response.body)
# Store returned identifiers securely. Recover uncertain payments before retrying.// Java 17+. Save as ZytePeExample.java and run on your server.
import java.net.URI;
import java.net.URLEncoder;
import java.net.http.*;
import java.nio.charset.StandardCharsets;
import java.time.Duration;
public class ZytePeExample {
private static String env(String name) {
String value = System.getenv(name);
if (value == null || value.isBlank()) throw new IllegalArgumentException("Set " + name);
return value;
}
public static void main(String[] args) throws Exception {
String path = "/api/v1/collections/intents/{short_id}/status";
path = path.replace("{short_id}", URLEncoder.encode(env("ZYTEPE_SHORT_ID"), StandardCharsets.UTF_8).replace("+", "%20"));
String query = "";
String body = ""; // GET requests have no body
var request = HttpRequest.newBuilder(URI.create(
"https://api.zytepe.com" + path + (query.isEmpty() ? "" : "?" + query)))
.timeout(Duration.ofSeconds(30));
request.method("GET", HttpRequest.BodyPublishers.noBody());
var client = HttpClient.newBuilder().connectTimeout(Duration.ofSeconds(10)).build();
var response = client.send(request.build(), HttpResponse.BodyHandlers.ofString(StandardCharsets.UTF_8));
if (response.statusCode() < 200 || response.statusCode() >= 300)
throw new IllegalStateException("HTTP " + response.statusCode());
String result = response.body(); // Parse JSON using your application's JSON library.
// Store identifiers securely. Recover uncertain payments before retrying.
}
}curl --request GET \
--url 'https://api.zytepe.com/api/v1/collections/intents/{short_id}/status'Path, query and headers
short_idRequiredpathUse the identifier returned by the corresponding creation operation.
Request body
No request body for GET.
Example response
{
"success": true,
"message": "Payment link status retrieved.",
"data": {
"status": "SUCCESS",
"short_id": "s0oJRkuT6OY",
"transaction_id": "ca9a58aa-d578-4fc2-a9f4-fb8d090d4b5f",
"current_usage_count": 1,
"usage_limit": 1,
"is_active": false
}
}