curl --request POST \
--url https://api.cloudcruise.com/error-codes \
--header 'Content-Type: application/json' \
--header 'cc-key: <api-key>' \
--data '
{
"error_code": "CLAIM_NOT_FOUND",
"description": "The claim number was not found in the payer portal",
"enriched_description": "<string>",
"retries": 1,
"retry_after": 1
}
'import requests
url = "https://api.cloudcruise.com/error-codes"
payload = {
"error_code": "CLAIM_NOT_FOUND",
"description": "The claim number was not found in the payer portal",
"enriched_description": "<string>",
"retries": 1,
"retry_after": 1
}
headers = {
"cc-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'cc-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
error_code: 'CLAIM_NOT_FOUND',
description: 'The claim number was not found in the payer portal',
enriched_description: '<string>',
retries: 1,
retry_after: 1
})
};
fetch('https://api.cloudcruise.com/error-codes', 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.cloudcruise.com/error-codes",
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([
'error_code' => 'CLAIM_NOT_FOUND',
'description' => 'The claim number was not found in the payer portal',
'enriched_description' => '<string>',
'retries' => 1,
'retry_after' => 1
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"cc-key: <api-key>"
],
]);
$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.cloudcruise.com/error-codes"
payload := strings.NewReader("{\n \"error_code\": \"CLAIM_NOT_FOUND\",\n \"description\": \"The claim number was not found in the payer portal\",\n \"enriched_description\": \"<string>\",\n \"retries\": 1,\n \"retry_after\": 1\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("cc-key", "<api-key>")
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.cloudcruise.com/error-codes")
.header("cc-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"error_code\": \"CLAIM_NOT_FOUND\",\n \"description\": \"The claim number was not found in the payer portal\",\n \"enriched_description\": \"<string>\",\n \"retries\": 1,\n \"retry_after\": 1\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.cloudcruise.com/error-codes")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["cc-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"error_code\": \"CLAIM_NOT_FOUND\",\n \"description\": \"The claim number was not found in the payer portal\",\n \"enriched_description\": \"<string>\",\n \"retries\": 1,\n \"retry_after\": 1\n}"
response = http.request(request)
puts response.read_body{
"created": true,
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"error_code": "<string>",
"description": "<string>",
"enriched_description": "<string>",
"error_action": "alert",
"retries": 123,
"retry_after": 123,
"workspace_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_at": "2023-11-07T05:31:56Z"
}Create error code
Creates an error code in the workspace associated with your API key, or returns the existing one with the same name.
Names match case- and whitespace-insensitively, so " claim_not_found " returns an existing CLAIM_NOT_FOUND. The response’s created field says which happened, so callers do not need to list codes first.
To use a code, set its id as the value of a node’s error_on_false_message (BOOL_CONDITION), selector_error_message (selector-based nodes) or error_message (USER_INTERACTION) parameter, then save the workflow.
curl --request POST \
--url https://api.cloudcruise.com/error-codes \
--header 'Content-Type: application/json' \
--header 'cc-key: <api-key>' \
--data '
{
"error_code": "CLAIM_NOT_FOUND",
"description": "The claim number was not found in the payer portal",
"enriched_description": "<string>",
"retries": 1,
"retry_after": 1
}
'import requests
url = "https://api.cloudcruise.com/error-codes"
payload = {
"error_code": "CLAIM_NOT_FOUND",
"description": "The claim number was not found in the payer portal",
"enriched_description": "<string>",
"retries": 1,
"retry_after": 1
}
headers = {
"cc-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'cc-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
error_code: 'CLAIM_NOT_FOUND',
description: 'The claim number was not found in the payer portal',
enriched_description: '<string>',
retries: 1,
retry_after: 1
})
};
fetch('https://api.cloudcruise.com/error-codes', 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.cloudcruise.com/error-codes",
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([
'error_code' => 'CLAIM_NOT_FOUND',
'description' => 'The claim number was not found in the payer portal',
'enriched_description' => '<string>',
'retries' => 1,
'retry_after' => 1
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"cc-key: <api-key>"
],
]);
$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.cloudcruise.com/error-codes"
payload := strings.NewReader("{\n \"error_code\": \"CLAIM_NOT_FOUND\",\n \"description\": \"The claim number was not found in the payer portal\",\n \"enriched_description\": \"<string>\",\n \"retries\": 1,\n \"retry_after\": 1\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("cc-key", "<api-key>")
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.cloudcruise.com/error-codes")
.header("cc-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"error_code\": \"CLAIM_NOT_FOUND\",\n \"description\": \"The claim number was not found in the payer portal\",\n \"enriched_description\": \"<string>\",\n \"retries\": 1,\n \"retry_after\": 1\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.cloudcruise.com/error-codes")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["cc-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"error_code\": \"CLAIM_NOT_FOUND\",\n \"description\": \"The claim number was not found in the payer portal\",\n \"enriched_description\": \"<string>\",\n \"retries\": 1,\n \"retry_after\": 1\n}"
response = http.request(request)
puts response.read_body{
"created": true,
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"error_code": "<string>",
"description": "<string>",
"enriched_description": "<string>",
"error_action": "alert",
"retries": 123,
"retry_after": 123,
"workspace_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_at": "2023-11-07T05:31:56Z"
}Authorizations
API key-based authentication. Provide your CloudCruise API key in the cc-key header.
Headers
CloudCruise API key for authentication
Body
Name of the error code. Must not be blank; leading and trailing whitespace is trimmed.
100"CLAIM_NOT_FOUND"
Short description of the error
"The claim number was not found in the payer portal"
Longer description used to classify errors against this code
What CloudCruise does when a run fails with this code
alert, cancel, pause, retry, input_required Number of retries when error_action is retry
x >= 0Seconds to wait between retries when error_action is retry
x >= 0Response
The created error code, or the existing one with the same name
true if a new code was created, false if an existing code with the same name was returned
Unique identifier. Use this value in a node's error-code parameter.
Name of the error code, e.g. CLAIM_NOT_FOUND
Short description of the error
Longer description used to classify errors against this code
What CloudCruise does when a run fails with this code
alert, cancel, pause, retry, input_required Number of retries when error_action is retry
Seconds to wait between retries when error_action is retry
ID of the workspace this error code belongs to
Timestamp when the error code was created
Was this page helpful?

