cURL
curl -X PATCH "https://api.easy-orders.net/api/partners-apps/v1/checkout-fields/6c2f8d3b-0e4a-4b7f-9c6d-2a3b4c5d6e70" \
-H "Authorization: Bearer $EASYORDERS_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "Mobile number",
"placeholder": "01xxxxxxxxx",
"position": 1
}'const response = await fetch('https://api.easy-orders.net/api/partners-apps/v1/checkout-fields/6c2f8d3b-0e4a-4b7f-9c6d-2a3b4c5d6e70', {
method: 'PATCH',
headers: {
Authorization: `Bearer ${process.env.EASYORDERS_ACCESS_TOKEN}`,
'Content-Type': 'application/json',
},
body: JSON.stringify({
name: 'Mobile number',
placeholder: '01xxxxxxxxx',
position: 1,
}),
})
const json = await response.json()
if (!response.ok) {
throw new Error(`${json.error.code}: ${json.error.message}`)
}
const { checkout_field } = jsonpackage main
import (
"bytes"
"encoding/json"
"fmt"
"net/http"
"os"
)
func main() {
body := []byte(`{
"name": "Mobile number",
"placeholder": "01xxxxxxxxx",
"position": 1
}`)
req, err := http.NewRequest("PATCH", "https://api.easy-orders.net/api/partners-apps/v1/checkout-fields/6c2f8d3b-0e4a-4b7f-9c6d-2a3b4c5d6e70", bytes.NewReader(body))
if err != nil {
panic(err)
}
req.Header.Set("Authorization", "Bearer "+os.Getenv("EASYORDERS_ACCESS_TOKEN"))
req.Header.Set("Content-Type", "application/json")
res, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer res.Body.Close()
var answer map[string]any
if err := json.NewDecoder(res.Body).Decode(&answer); err != nil {
panic(err)
}
if res.StatusCode >= 300 {
panic(fmt.Sprint(res.Status, answer["error"]))
}
fmt.Println(answer["checkout_field"])
}<?php
$ch = curl_init('https://api.easy-orders.net/api/partners-apps/v1/checkout-fields/6c2f8d3b-0e4a-4b7f-9c6d-2a3b4c5d6e70');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'PATCH',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . getenv('EASYORDERS_ACCESS_TOKEN'),
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => json_encode([
'name' => 'Mobile number',
'placeholder' => '01xxxxxxxxx',
'position' => 1,
]),
]);
$answer = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
curl_close($ch);
if ($status >= 300) {
throw new RuntimeException($answer['error']['code'] . ': ' . $answer['error']['message']);
}
$checkoutField = $answer['checkout_field'];import os
import requests
response = requests.patch(
"https://api.easy-orders.net/api/partners-apps/v1/checkout-fields/6c2f8d3b-0e4a-4b7f-9c6d-2a3b4c5d6e70",
headers={
"Authorization": f"Bearer {os.environ['EASYORDERS_ACCESS_TOKEN']}",
},
json={
"name": "Mobile number",
"placeholder": "01xxxxxxxxx",
"position": 1,
},
timeout=30,
)
answer = response.json()
if not response.ok:
raise RuntimeError(f"{answer['error']['code']}: {answer['error']['message']}")
checkout_field = answer["checkout_field"]{
"checkout_field": {
"id": "6c2f8d3b-0e4a-4b7f-9c6d-2a3b4c5d6e70",
"key": "phone",
"name": "Mobile number",
"type": "input",
"placeholder": "01xxxxxxxxx",
"position": 1,
"is_active": true,
"is_required": true
}
}{
"error": {
"code": "invalid_request",
"message": "Invalid JSON body: unknown field"
}
}{
"error": {
"code": "unauthenticated",
"message": "Missing or invalid access token"
}
}{
"error": {
"code": "payment_required",
"message": "The app's subscription on this store is suspended"
}
}{
"error": {
"code": "insufficient_scope",
"message": "This request requires the scope: read_orders",
"details": {
"required_scope": "read_orders"
}
}
}{
"error": {
"code": "not_found",
"message": "Resource not found"
}
}{
"error": {
"code": "validation_failed",
"message": "Validation failed",
"details": {
"fields": [
{
"field": "is_required",
"rule": "always_required",
"param": "phone"
}
]
}
}
}{
"error": {
"code": "too_many_requests",
"message": "Rate limit exceeded"
}
}Checkout fields
Update a checkout field
Scope: write_checkout_form
Changes the field’s label (name), placeholder, position, and
whether it shows (is_active) and is required (is_required). Only
the fields you send change; null is refused. key and type
cannot change: sending them answers 400.
full_name and phone are needed by every order: they stay shown
and required. Setting is_active or is_required to false on them
answers 422 with the rule always_required.
The storefront’s checkout shows the change at once.
PATCH
/
checkout-fields
/
{id}
cURL
curl -X PATCH "https://api.easy-orders.net/api/partners-apps/v1/checkout-fields/6c2f8d3b-0e4a-4b7f-9c6d-2a3b4c5d6e70" \
-H "Authorization: Bearer $EASYORDERS_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "Mobile number",
"placeholder": "01xxxxxxxxx",
"position": 1
}'const response = await fetch('https://api.easy-orders.net/api/partners-apps/v1/checkout-fields/6c2f8d3b-0e4a-4b7f-9c6d-2a3b4c5d6e70', {
method: 'PATCH',
headers: {
Authorization: `Bearer ${process.env.EASYORDERS_ACCESS_TOKEN}`,
'Content-Type': 'application/json',
},
body: JSON.stringify({
name: 'Mobile number',
placeholder: '01xxxxxxxxx',
position: 1,
}),
})
const json = await response.json()
if (!response.ok) {
throw new Error(`${json.error.code}: ${json.error.message}`)
}
const { checkout_field } = jsonpackage main
import (
"bytes"
"encoding/json"
"fmt"
"net/http"
"os"
)
func main() {
body := []byte(`{
"name": "Mobile number",
"placeholder": "01xxxxxxxxx",
"position": 1
}`)
req, err := http.NewRequest("PATCH", "https://api.easy-orders.net/api/partners-apps/v1/checkout-fields/6c2f8d3b-0e4a-4b7f-9c6d-2a3b4c5d6e70", bytes.NewReader(body))
if err != nil {
panic(err)
}
req.Header.Set("Authorization", "Bearer "+os.Getenv("EASYORDERS_ACCESS_TOKEN"))
req.Header.Set("Content-Type", "application/json")
res, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer res.Body.Close()
var answer map[string]any
if err := json.NewDecoder(res.Body).Decode(&answer); err != nil {
panic(err)
}
if res.StatusCode >= 300 {
panic(fmt.Sprint(res.Status, answer["error"]))
}
fmt.Println(answer["checkout_field"])
}<?php
$ch = curl_init('https://api.easy-orders.net/api/partners-apps/v1/checkout-fields/6c2f8d3b-0e4a-4b7f-9c6d-2a3b4c5d6e70');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'PATCH',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . getenv('EASYORDERS_ACCESS_TOKEN'),
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => json_encode([
'name' => 'Mobile number',
'placeholder' => '01xxxxxxxxx',
'position' => 1,
]),
]);
$answer = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
curl_close($ch);
if ($status >= 300) {
throw new RuntimeException($answer['error']['code'] . ': ' . $answer['error']['message']);
}
$checkoutField = $answer['checkout_field'];import os
import requests
response = requests.patch(
"https://api.easy-orders.net/api/partners-apps/v1/checkout-fields/6c2f8d3b-0e4a-4b7f-9c6d-2a3b4c5d6e70",
headers={
"Authorization": f"Bearer {os.environ['EASYORDERS_ACCESS_TOKEN']}",
},
json={
"name": "Mobile number",
"placeholder": "01xxxxxxxxx",
"position": 1,
},
timeout=30,
)
answer = response.json()
if not response.ok:
raise RuntimeError(f"{answer['error']['code']}: {answer['error']['message']}")
checkout_field = answer["checkout_field"]{
"checkout_field": {
"id": "6c2f8d3b-0e4a-4b7f-9c6d-2a3b4c5d6e70",
"key": "phone",
"name": "Mobile number",
"type": "input",
"placeholder": "01xxxxxxxxx",
"position": 1,
"is_active": true,
"is_required": true
}
}{
"error": {
"code": "invalid_request",
"message": "Invalid JSON body: unknown field"
}
}{
"error": {
"code": "unauthenticated",
"message": "Missing or invalid access token"
}
}{
"error": {
"code": "payment_required",
"message": "The app's subscription on this store is suspended"
}
}{
"error": {
"code": "insufficient_scope",
"message": "This request requires the scope: read_orders",
"details": {
"required_scope": "read_orders"
}
}
}{
"error": {
"code": "not_found",
"message": "Resource not found"
}
}{
"error": {
"code": "validation_failed",
"message": "Validation failed",
"details": {
"fields": [
{
"field": "is_required",
"rule": "always_required",
"param": "phone"
}
]
}
}
}{
"error": {
"code": "too_many_requests",
"message": "Rate limit exceeded"
}
}Authorizations
An access token from the OAuth flow (eo_at_...). It lasts one hour;
refresh it with the refresh token. See Authentication.
Body
application/json
Every field is optional; only the fields sent change.