curl --request POST \
--url https://api.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post', 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.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"owner_type": "<string>",
"original_name": "<string>",
"row_count": 123,
"status": "<string>",
"error_count": 123,
"posted_journal_entry_ids": [
"<unknown>"
],
"rows": "<array>",
"created_by": "<string>",
"created_by_type": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"message": "<string>",
"errors": {}
}Post imported entries (organization)
Turns a validated import file into real accounting entries, all at once (organization space).
curl --request POST \
--url https://api.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post', 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.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.exowpee.com/v1/accounting/organization/books/{entryImport}/entry-imports/{entry_import}/post")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"owner_type": "<string>",
"original_name": "<string>",
"row_count": 123,
"status": "<string>",
"error_count": 123,
"posted_journal_entry_ids": [
"<unknown>"
],
"rows": "<array>",
"created_by": "<string>",
"created_by_type": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"message": "<string>",
"errors": {}
}entry_imports.post
Conditions
- The book is the one selected for the request: the {book} segment in the organization space, or the client account’s own books in the client space.
- The accounting module must be included in the plan of the organization.
- The book must be set up for accounting (it must have at least one journal).
- The import must belong to the selected book.
- An import already posted is refused.
- An import with errors (rejected status or error_count above zero) is refused.
- Each entry is checked again when posted: its date must fall in an open fiscal period, the journal and accounts must still exist, and the entry must satisfy the usual posting rules. One refused entry cancels the whole batch.
- Posts one journal entry per entry number of the file, in the journal named on its rows, with the batch as source and no fee applied.
- Sets the import to posted and records the identifiers of the posted entries in posted_journal_entry_ids.
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Identifier of the book (first path segment of the organization space; the generated name is a documentation quirk).
Identifier of the entry import in the book.
Query Parameters
Response mode. Default none; none answers 204 No Content.
none, resource Comma-separated JSON keys of the root resource (id is always rendered). Available: id, owner_type, original_name, row_count, status, error_count, posted_journal_entry_ids, created_by, created_by_type, created_at, updated_at.
Comma-separated include paths, each optionally followed by its fields in parentheses: units(id,sku),units.uomUnit(id,name). Max depth 6, max 40 paths. Available: rows.
Response
Resource (only with response=resource).
Identifier of the import, a 27-character KSUID.
Kind of book the import belongs to (the organization's own books or a client account's books).
Name of the uploaded file as uploaded, shortened if too long.
Number of data rows read from the file, header excluded.
Import state: staged (being created), validated (no row error, ready to post), rejected (at least one row error, cannot be posted) or posted (entries written). Set by the server.
Number of rows that have at least one error.
Identifiers of the journal entries posted from this import, in file order. Null until the import is posted.
Rows of the file with their raw values and errors. Returned only with ?include=rows, on the show route and when the caller holds the entry_imports.retrieve permission.
Identifier of the member or agent account that uploaded the file; null when no actor could be resolved.
Kind of actor in created_by (member or agent account); null when no actor could be resolved.
Date and time the record was created (ISO 8601, UTC).
Date and time the record was last changed (ISO 8601, UTC).