Update an import configuration
curl --request PATCH \
--url https://clarus-api.com/api/import_configurations/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-Clarus-Subdomain: <api-key>' \
--data '
{
"data": {
"type": "import_configurations",
"attributes": {
"name": "<string>",
"settings": [
{
"setting_type": "delimiter",
"value": ","
}
],
"pre_processors": [
{
"action": "dig",
"configuration": {
"path": "root.GoodsOut"
},
"sequence": 1
}
],
"automatic_processing_flows": [
{
"code": "process_order",
"name": "Process Order",
"sequence": 1,
"conditions": {},
"processing_actions": [
{
"action": "find_resource",
"configuration": {
"resource_name": "account",
"resource_attribute": "code",
"index": "AccountCode"
}
}
]
}
],
"manual_processing_flows": [
{
"code": "process_order",
"name": "Process Order",
"sequence": 1,
"conditions": {},
"processing_actions": [
{
"action": "find_resource",
"configuration": {
"resource_name": "account",
"resource_attribute": "code",
"index": "AccountCode"
}
}
]
}
]
}
}
}
'import requests
url = "https://clarus-api.com/api/import_configurations/{id}"
payload = { "data": {
"type": "import_configurations",
"attributes": {
"name": "<string>",
"settings": [
{
"setting_type": "delimiter",
"value": ","
}
],
"pre_processors": [
{
"action": "dig",
"configuration": { "path": "root.GoodsOut" },
"sequence": 1
}
],
"automatic_processing_flows": [
{
"code": "process_order",
"name": "Process Order",
"sequence": 1,
"conditions": {},
"processing_actions": [
{
"action": "find_resource",
"configuration": {
"resource_name": "account",
"resource_attribute": "code",
"index": "AccountCode"
}
}
]
}
],
"manual_processing_flows": [
{
"code": "process_order",
"name": "Process Order",
"sequence": 1,
"conditions": {},
"processing_actions": [
{
"action": "find_resource",
"configuration": {
"resource_name": "account",
"resource_attribute": "code",
"index": "AccountCode"
}
}
]
}
]
}
} }
headers = {
"Authorization": "Bearer <token>",
"X-Clarus-Subdomain": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {
Authorization: 'Bearer <token>',
'X-Clarus-Subdomain': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
data: {
type: 'import_configurations',
attributes: {
name: '<string>',
settings: [{setting_type: 'delimiter', value: ','}],
pre_processors: [{action: 'dig', configuration: {path: 'root.GoodsOut'}, sequence: 1}],
automatic_processing_flows: [
{
code: 'process_order',
name: 'Process Order',
sequence: 1,
conditions: {},
processing_actions: [
{
action: 'find_resource',
configuration: {resource_name: 'account', resource_attribute: 'code', index: 'AccountCode'}
}
]
}
],
manual_processing_flows: [
{
code: 'process_order',
name: 'Process Order',
sequence: 1,
conditions: {},
processing_actions: [
{
action: 'find_resource',
configuration: {resource_name: 'account', resource_attribute: 'code', index: 'AccountCode'}
}
]
}
]
}
}
})
};
fetch('https://clarus-api.com/api/import_configurations/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"error": "<string>"
}{
"errors": [
{
"code": 123,
"symbol": "<string>",
"details": "<string>",
"source": "<string>",
"context": {}
}
]
}{
"errors": [
{
"code": 123,
"symbol": "<string>",
"details": "<string>",
"source": "<string>",
"context": {}
}
]
}Import Configurations
Update an import configuration
Update an existing import configuration.
PATCH
/
api
/
import_configurations
/
{id}
Update an import configuration
curl --request PATCH \
--url https://clarus-api.com/api/import_configurations/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-Clarus-Subdomain: <api-key>' \
--data '
{
"data": {
"type": "import_configurations",
"attributes": {
"name": "<string>",
"settings": [
{
"setting_type": "delimiter",
"value": ","
}
],
"pre_processors": [
{
"action": "dig",
"configuration": {
"path": "root.GoodsOut"
},
"sequence": 1
}
],
"automatic_processing_flows": [
{
"code": "process_order",
"name": "Process Order",
"sequence": 1,
"conditions": {},
"processing_actions": [
{
"action": "find_resource",
"configuration": {
"resource_name": "account",
"resource_attribute": "code",
"index": "AccountCode"
}
}
]
}
],
"manual_processing_flows": [
{
"code": "process_order",
"name": "Process Order",
"sequence": 1,
"conditions": {},
"processing_actions": [
{
"action": "find_resource",
"configuration": {
"resource_name": "account",
"resource_attribute": "code",
"index": "AccountCode"
}
}
]
}
]
}
}
}
'import requests
url = "https://clarus-api.com/api/import_configurations/{id}"
payload = { "data": {
"type": "import_configurations",
"attributes": {
"name": "<string>",
"settings": [
{
"setting_type": "delimiter",
"value": ","
}
],
"pre_processors": [
{
"action": "dig",
"configuration": { "path": "root.GoodsOut" },
"sequence": 1
}
],
"automatic_processing_flows": [
{
"code": "process_order",
"name": "Process Order",
"sequence": 1,
"conditions": {},
"processing_actions": [
{
"action": "find_resource",
"configuration": {
"resource_name": "account",
"resource_attribute": "code",
"index": "AccountCode"
}
}
]
}
],
"manual_processing_flows": [
{
"code": "process_order",
"name": "Process Order",
"sequence": 1,
"conditions": {},
"processing_actions": [
{
"action": "find_resource",
"configuration": {
"resource_name": "account",
"resource_attribute": "code",
"index": "AccountCode"
}
}
]
}
]
}
} }
headers = {
"Authorization": "Bearer <token>",
"X-Clarus-Subdomain": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {
Authorization: 'Bearer <token>',
'X-Clarus-Subdomain': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
data: {
type: 'import_configurations',
attributes: {
name: '<string>',
settings: [{setting_type: 'delimiter', value: ','}],
pre_processors: [{action: 'dig', configuration: {path: 'root.GoodsOut'}, sequence: 1}],
automatic_processing_flows: [
{
code: 'process_order',
name: 'Process Order',
sequence: 1,
conditions: {},
processing_actions: [
{
action: 'find_resource',
configuration: {resource_name: 'account', resource_attribute: 'code', index: 'AccountCode'}
}
]
}
],
manual_processing_flows: [
{
code: 'process_order',
name: 'Process Order',
sequence: 1,
conditions: {},
processing_actions: [
{
action: 'find_resource',
configuration: {resource_name: 'account', resource_attribute: 'code', index: 'AccountCode'}
}
]
}
]
}
}
})
};
fetch('https://clarus-api.com/api/import_configurations/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"error": "<string>"
}{
"errors": [
{
"code": 123,
"symbol": "<string>",
"details": "<string>",
"source": "<string>",
"context": {}
}
]
}{
"errors": [
{
"code": 123,
"symbol": "<string>",
"details": "<string>",
"source": "<string>",
"context": {}
}
]
}Request Structure
{
"data": {
"type": "import_configurations",
"attributes": {
"name": "Acme Orders CSV (v2)",
"failure_strategy": "abort"
}
}
}
Key Fields
| Field | Required | Description |
|---|---|---|
name | No | Configuration name |
parser | No | File format parser |
failure_strategy | No | skip_resource or abort |
settings / pre_processors / automatic_processing_flows / manual_processing_flows | No | Replace the corresponding configuration sections |
Authorizations
OAuth 2.0 authentication. Use the client credentials or authorization code flow to obtain an access token.
The subdomain/tenant name identifying which tenant's data to access. Required for all API requests.
Path Parameters
The unique identifier of the import configuration to update
Body
application/json
Show child attributes
Show child attributes
Response
Operation completed successfully with no content to return
⌘I

