curl -X POST "https://api-integration.ollang.com/integration/orders/cancel/60b8d6f1e1b9b1d8c6c0d8e1" \
-H "X-Api-Key: <your-api-key>"
const orderId = "60b8d6f1e1b9b1d8c6c0d8e1";
const response = await fetch(
`https://api-integration.ollang.com/integration/orders/cancel/${orderId}`,
{
method: "POST",
headers: {
"X-Api-Key": "<your-api-key>",
},
}
);
if (response.status === 204) {
console.log("Order cancelled successfully");
}
import requests
order_id = "60b8d6f1e1b9b1d8c6c0d8e1"
headers = {
'X-Api-Key': '<your-api-key>'
}
response = requests.post(
f'https://api-integration.ollang.com/integration/orders/cancel/{order_id}',
headers=headers
)
if response.status_code == 204:
print("Order cancelled successfully")
$orderId = '60b8d6f1e1b9b1d8c6c0d8e1';
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://api-integration.ollang.com/integration/orders/cancel/' . $orderId,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_HTTPHEADER => array(
'X-Api-Key: <your-api-key>'
),
));
$response = curl_exec($curl);
$httpCode = curl_getinfo($curl, CURLINFO_HTTP_CODE);
curl_close($curl);
if ($httpCode === 204) {
echo "Order cancelled successfully";
}
package main
import (
"fmt"
"net/http"
)
func main() {
orderId := "60b8d6f1e1b9b1d8c6c0d8e1"
url := fmt.Sprintf("https://api-integration.ollang.com/integration/orders/cancel/%s", orderId)
req, _ := http.NewRequest("POST", url, nil)
req.Header.Set("X-Api-Key", "<your-api-key>")
client := &http.Client{}
resp, _ := client.Do(req)
if resp.StatusCode == 204 {
fmt.Println("Order cancelled successfully")
}
}
String orderId = "60b8d6f1e1b9b1d8c6c0d8e1";
HttpResponse<String> response = Unirest.post("https://api-integration.ollang.com/integration/orders/cancel/" + orderId)
.header("X-Api-Key", "<your-api-key>")
.asString();
if (response.getStatus() == 204) {
System.out.println("Order cancelled successfully");
}
No content - Order cancelled successfully
{
"error": "Order not found",
"message": "No order found with the provided orderId",
"code": "ORDER_NOT_FOUND"
}
{
"error": "Cannot cancel order",
"message": "Order cannot be cancelled because it is already in progress or completed",
"code": "ORDER_NOT_CANCELLABLE"
}
{
"error": "Access denied",
"message": "You don't have permission to cancel this order",
"code": "ACCESS_DENIED"
}
{
"error": "Order already cancelled",
"message": "This order has already been cancelled",
"code": "ORDER_ALREADY_CANCELLED"
}
{
"error": "Unauthorized",
"message": "Invalid or missing API key",
"code": "UNAUTHORIZED"
}
Ollang API Reference
Cancel Order
Cancel an existing translation order that is no longer needed
POST
/
integration
/
orders
/
cancel
/
{orderId}
curl -X POST "https://api-integration.ollang.com/integration/orders/cancel/60b8d6f1e1b9b1d8c6c0d8e1" \
-H "X-Api-Key: <your-api-key>"
const orderId = "60b8d6f1e1b9b1d8c6c0d8e1";
const response = await fetch(
`https://api-integration.ollang.com/integration/orders/cancel/${orderId}`,
{
method: "POST",
headers: {
"X-Api-Key": "<your-api-key>",
},
}
);
if (response.status === 204) {
console.log("Order cancelled successfully");
}
import requests
order_id = "60b8d6f1e1b9b1d8c6c0d8e1"
headers = {
'X-Api-Key': '<your-api-key>'
}
response = requests.post(
f'https://api-integration.ollang.com/integration/orders/cancel/{order_id}',
headers=headers
)
if response.status_code == 204:
print("Order cancelled successfully")
$orderId = '60b8d6f1e1b9b1d8c6c0d8e1';
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://api-integration.ollang.com/integration/orders/cancel/' . $orderId,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_HTTPHEADER => array(
'X-Api-Key: <your-api-key>'
),
));
$response = curl_exec($curl);
$httpCode = curl_getinfo($curl, CURLINFO_HTTP_CODE);
curl_close($curl);
if ($httpCode === 204) {
echo "Order cancelled successfully";
}
package main
import (
"fmt"
"net/http"
)
func main() {
orderId := "60b8d6f1e1b9b1d8c6c0d8e1"
url := fmt.Sprintf("https://api-integration.ollang.com/integration/orders/cancel/%s", orderId)
req, _ := http.NewRequest("POST", url, nil)
req.Header.Set("X-Api-Key", "<your-api-key>")
client := &http.Client{}
resp, _ := client.Do(req)
if resp.StatusCode == 204 {
fmt.Println("Order cancelled successfully")
}
}
String orderId = "60b8d6f1e1b9b1d8c6c0d8e1";
HttpResponse<String> response = Unirest.post("https://api-integration.ollang.com/integration/orders/cancel/" + orderId)
.header("X-Api-Key", "<your-api-key>")
.asString();
if (response.getStatus() == 204) {
System.out.println("Order cancelled successfully");
}
No content - Order cancelled successfully
{
"error": "Order not found",
"message": "No order found with the provided orderId",
"code": "ORDER_NOT_FOUND"
}
{
"error": "Cannot cancel order",
"message": "Order cannot be cancelled because it is already in progress or completed",
"code": "ORDER_NOT_CANCELLABLE"
}
{
"error": "Access denied",
"message": "You don't have permission to cancel this order",
"code": "ACCESS_DENIED"
}
{
"error": "Order already cancelled",
"message": "This order has already been cancelled",
"code": "ORDER_ALREADY_CANCELLED"
}
{
"error": "Unauthorized",
"message": "Invalid or missing API key",
"code": "UNAUTHORIZED"
}
Cancel an existing translation order that is no longer needed. This action is typically irreversible, so use it carefully. Only orders in certain statuses can be cancelled.
curl -X POST "https://api-integration.ollang.com/integration/orders/cancel/60b8d6f1e1b9b1d8c6c0d8e1" \
-H "X-Api-Key: <your-api-key>"
const orderId = "60b8d6f1e1b9b1d8c6c0d8e1";
const response = await fetch(
`https://api-integration.ollang.com/integration/orders/cancel/${orderId}`,
{
method: "POST",
headers: {
"X-Api-Key": "<your-api-key>",
},
}
);
if (response.status === 204) {
console.log("Order cancelled successfully");
}
import requests
order_id = "60b8d6f1e1b9b1d8c6c0d8e1"
headers = {
'X-Api-Key': '<your-api-key>'
}
response = requests.post(
f'https://api-integration.ollang.com/integration/orders/cancel/{order_id}',
headers=headers
)
if response.status_code == 204:
print("Order cancelled successfully")
$orderId = '60b8d6f1e1b9b1d8c6c0d8e1';
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://api-integration.ollang.com/integration/orders/cancel/' . $orderId,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_HTTPHEADER => array(
'X-Api-Key: <your-api-key>'
),
));
$response = curl_exec($curl);
$httpCode = curl_getinfo($curl, CURLINFO_HTTP_CODE);
curl_close($curl);
if ($httpCode === 204) {
echo "Order cancelled successfully";
}
package main
import (
"fmt"
"net/http"
)
func main() {
orderId := "60b8d6f1e1b9b1d8c6c0d8e1"
url := fmt.Sprintf("https://api-integration.ollang.com/integration/orders/cancel/%s", orderId)
req, _ := http.NewRequest("POST", url, nil)
req.Header.Set("X-Api-Key", "<your-api-key>")
client := &http.Client{}
resp, _ := client.Do(req)
if resp.StatusCode == 204 {
fmt.Println("Order cancelled successfully")
}
}
String orderId = "60b8d6f1e1b9b1d8c6c0d8e1";
HttpResponse<String> response = Unirest.post("https://api-integration.ollang.com/integration/orders/cancel/" + orderId)
.header("X-Api-Key", "<your-api-key>")
.asString();
if (response.getStatus() == 204) {
System.out.println("Order cancelled successfully");
}
Authorizations
This endpoint requires API key authentication. Include your API key in the request header:- Header name:
X-Api-Key - Header value: Your API key from the Ollang dashboard
- Format:
X-Api-Key: your-api-key-here
Path Parameters
The unique identifier of the order you want to cancel. This should be a valid
order ID that you have access to and that is eligible for cancellation.
Important Notes
Order Cancellation is IrreversibleOnce an order is cancelled, it cannot be restored. Make sure you really want to cancel the order before making this request.
Cancellation EligibilityNot all orders can be cancelled. Orders that are already in progress, completed, or delivered typically cannot be cancelled. Only orders in
pending or early ongoing status are usually eligible for cancellation.Response
This endpoint returns no content on successful cancellation (HTTP 204 status code). The absence of an error response indicates that the order was successfully cancelled.No content - Order cancelled successfully
{
"error": "Order not found",
"message": "No order found with the provided orderId",
"code": "ORDER_NOT_FOUND"
}
{
"error": "Cannot cancel order",
"message": "Order cannot be cancelled because it is already in progress or completed",
"code": "ORDER_NOT_CANCELLABLE"
}
{
"error": "Access denied",
"message": "You don't have permission to cancel this order",
"code": "ACCESS_DENIED"
}
{
"error": "Order already cancelled",
"message": "This order has already been cancelled",
"code": "ORDER_ALREADY_CANCELLED"
}
{
"error": "Unauthorized",
"message": "Invalid or missing API key",
"code": "UNAUTHORIZED"
}
Was this page helpful?
⌘I