Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: add API documentation for document import meta-data #1

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,40 @@ curl -X POST \
https://app.domonda.com/api/public/upload
```

It's also possible to upload a document metadata together with the document.
For example, upload `ebinterface.xml` incoming invoice together with `matadata.json`:

```sh
curl -X POST
-H "Authorization: Bearer API_KEY"
-H "Content-Type: multipart/form-data"
-F "documentType=INCOMING_INVOICE"
-F "[email protected]"
-F "[email protected]"
https://app.domonda.com/api/public/upload
```

An example of attached `metadata.json` file:

```json
{
"tags": [
"tag1",
"tag2",
"tag3"
],
"invoiceTitle": "I'm an awesome invoice title",
"costCenter": [
{
"str": "NEW WAREHOUSE",
"name": "New Warehouse",
"currency": "EUR",
"amount": 25.5
}
]
}
```

The response will be a HTTP status code 200 message with the created document's UUID in plaintext format:

```txt
Expand Down