Storecove API
POST
Create a new AdditionalTaxIdentifier
{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers
QUERY PARAMS
legal_entity_id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/post "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers")
require "http/client"
url = "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers"
response = HTTP::Client.post url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers");
var request = new RestRequest("", Method.Post);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers"))
.method("POST", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers")
.post(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('POST', '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'POST',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers';
const options = {method: 'POST'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers',
method: 'POST',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers")
.post(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'POST',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'POST',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('POST', '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'POST',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers';
const options = {method: 'POST'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers" in
Client.call `POST uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('POST', '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers');
$request->setMethod(HTTP_METH_POST);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers');
$request->setRequestMethod('POST');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers' -Method POST
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers' -Method POST
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("POST", "/baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers"
response = requests.post(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers"
response <- VERB("POST", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.post('/baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers";
let client = reqwest::Client::new();
let response = client.post(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request POST \
--url {{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers
http POST {{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers
wget --quiet \
--method POST \
--output-document \
- {{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "POST"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
DELETE
Delete AdditionalTaxIdentifier
{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id
QUERY PARAMS
legal_entity_id
id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/delete "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
require "http/client"
url = "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"
response = HTTP::Client.delete url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Delete,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id");
var request = new RestRequest("", Method.Delete);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"
req, _ := http.NewRequest("DELETE", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
DELETE /baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers/:id HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("DELETE", "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"))
.method("DELETE", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
.delete(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.delete("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('DELETE', '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'DELETE',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id';
const options = {method: 'DELETE'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id',
method: 'DELETE',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
.delete(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'DELETE',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers/:id',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'DELETE',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('DELETE', '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'DELETE',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id';
const options = {method: 'DELETE'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"DELETE"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id" in
Client.call `DELETE uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('DELETE', '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
$request->setMethod(HTTP_METH_DELETE);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
$request->setRequestMethod('DELETE');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id' -Method DELETE
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id' -Method DELETE
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("DELETE", "/baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"
response = requests.delete(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"
response <- VERB("DELETE", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.delete('/baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers/:id') do |req|
end
puts response.status
puts response.body
use std::str::FromStr;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id";
let client = reqwest::Client::new();
let response = client.request(reqwest::Method::from_str("DELETE").unwrap(), url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request DELETE \
--url {{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id
http DELETE {{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id
wget --quiet \
--method DELETE \
--output-document \
- {{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "DELETE"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
GET
Get AdditionalTaxIdentifier
{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id
QUERY PARAMS
legal_entity_id
id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/get "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
require "http/client"
url = "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"
response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers/:id HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
.get()
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('GET', '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'GET',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id',
method: 'GET',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
.get()
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'GET',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers/:id',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'GET',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('GET', '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'GET',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id" in
Client.call `GET uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('GET', '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
$request->setMethod(HTTP_METH_GET);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id' -Method GET
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id' -Method GET
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("GET", "/baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"
response = requests.get(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"
response <- VERB("GET", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.get('/baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers/:id') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id";
let client = reqwest::Client::new();
let response = client.get(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request GET \
--url {{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id
http GET {{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id
wget --quiet \
--method GET \
--output-document \
- {{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "GET"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
PATCH
Update AdditionalTaxIdentifier
{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id
QUERY PARAMS
legal_entity_id
id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "PATCH");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/patch "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
require "http/client"
url = "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"
response = HTTP::Client.patch url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Patch,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id");
var request = new RestRequest("", Method.Patch);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"
req, _ := http.NewRequest("PATCH", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
PATCH /baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers/:id HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("PATCH", "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"))
.method("PATCH", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
.patch(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.patch("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('PATCH', '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'PATCH',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id';
const options = {method: 'PATCH'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id',
method: 'PATCH',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
.patch(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'PATCH',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers/:id',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'PATCH',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('PATCH', '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'PATCH',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id';
const options = {method: 'PATCH'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"PATCH"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id" in
Client.call `PATCH uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('PATCH', '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
$request->setMethod(HttpRequest::HTTP_METH_PATCH);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id');
$request->setRequestMethod('PATCH');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id' -Method PATCH
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id' -Method PATCH
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("PATCH", "/baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"
response = requests.patch(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id"
response <- VERB("PATCH", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.patch('/baseUrl/legal_entities/:legal_entity_id/additional_tax_identifiers/:id') do |req|
end
puts response.status
puts response.body
use std::str::FromStr;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id";
let client = reqwest::Client::new();
let response = client.request(reqwest::Method::from_str("PATCH").unwrap(), url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request PATCH \
--url {{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id
http PATCH {{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id
wget --quiet \
--method PATCH \
--output-document \
- {{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:legal_entity_id/additional_tax_identifiers/:id")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "PATCH"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
POST
Create a new Administration
{{baseUrl}}/legal_entities/:legal_entity_id/administrations
QUERY PARAMS
legal_entity_id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:legal_entity_id/administrations");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/post "{{baseUrl}}/legal_entities/:legal_entity_id/administrations")
require "http/client"
url = "{{baseUrl}}/legal_entities/:legal_entity_id/administrations"
response = HTTP::Client.post url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:legal_entity_id/administrations"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:legal_entity_id/administrations");
var request = new RestRequest("", Method.Post);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:legal_entity_id/administrations"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /baseUrl/legal_entities/:legal_entity_id/administrations HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/legal_entities/:legal_entity_id/administrations")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:legal_entity_id/administrations"))
.method("POST", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/administrations")
.post(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/legal_entities/:legal_entity_id/administrations")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('POST', '{{baseUrl}}/legal_entities/:legal_entity_id/administrations');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'POST',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/administrations';
const options = {method: 'POST'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations',
method: 'POST',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/administrations")
.post(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'POST',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:legal_entity_id/administrations',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'POST',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('POST', '{{baseUrl}}/legal_entities/:legal_entity_id/administrations');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'POST',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/administrations';
const options = {method: 'POST'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:legal_entity_id/administrations"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:legal_entity_id/administrations" in
Client.call `POST uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:legal_entity_id/administrations",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('POST', '{{baseUrl}}/legal_entities/:legal_entity_id/administrations');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:legal_entity_id/administrations');
$request->setMethod(HTTP_METH_POST);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:legal_entity_id/administrations');
$request->setRequestMethod('POST');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/administrations' -Method POST
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/administrations' -Method POST
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("POST", "/baseUrl/legal_entities/:legal_entity_id/administrations")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:legal_entity_id/administrations"
response = requests.post(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:legal_entity_id/administrations"
response <- VERB("POST", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:legal_entity_id/administrations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.post('/baseUrl/legal_entities/:legal_entity_id/administrations') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:legal_entity_id/administrations";
let client = reqwest::Client::new();
let response = client.post(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request POST \
--url {{baseUrl}}/legal_entities/:legal_entity_id/administrations
http POST {{baseUrl}}/legal_entities/:legal_entity_id/administrations
wget --quiet \
--method POST \
--output-document \
- {{baseUrl}}/legal_entities/:legal_entity_id/administrations
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:legal_entity_id/administrations")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "POST"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
DELETE
Delete Administration
{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id
QUERY PARAMS
legal_entity_id
id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/delete "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
require "http/client"
url = "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"
response = HTTP::Client.delete url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Delete,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id");
var request = new RestRequest("", Method.Delete);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"
req, _ := http.NewRequest("DELETE", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
DELETE /baseUrl/legal_entities/:legal_entity_id/administrations/:id HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("DELETE", "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"))
.method("DELETE", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
.delete(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.delete("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('DELETE', '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'DELETE',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id';
const options = {method: 'DELETE'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id',
method: 'DELETE',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
.delete(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'DELETE',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:legal_entity_id/administrations/:id',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'DELETE',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('DELETE', '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'DELETE',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id';
const options = {method: 'DELETE'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"DELETE"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id" in
Client.call `DELETE uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('DELETE', '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
$request->setMethod(HTTP_METH_DELETE);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
$request->setRequestMethod('DELETE');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id' -Method DELETE
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id' -Method DELETE
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("DELETE", "/baseUrl/legal_entities/:legal_entity_id/administrations/:id")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"
response = requests.delete(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"
response <- VERB("DELETE", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.delete('/baseUrl/legal_entities/:legal_entity_id/administrations/:id') do |req|
end
puts response.status
puts response.body
use std::str::FromStr;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id";
let client = reqwest::Client::new();
let response = client.request(reqwest::Method::from_str("DELETE").unwrap(), url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request DELETE \
--url {{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id
http DELETE {{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id
wget --quiet \
--method DELETE \
--output-document \
- {{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "DELETE"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
GET
Get Administration
{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id
QUERY PARAMS
legal_entity_id
id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/get "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
require "http/client"
url = "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"
response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /baseUrl/legal_entities/:legal_entity_id/administrations/:id HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
.get()
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('GET', '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'GET',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id',
method: 'GET',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
.get()
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'GET',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:legal_entity_id/administrations/:id',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'GET',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('GET', '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'GET',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id" in
Client.call `GET uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('GET', '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
$request->setMethod(HTTP_METH_GET);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id' -Method GET
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id' -Method GET
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("GET", "/baseUrl/legal_entities/:legal_entity_id/administrations/:id")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"
response = requests.get(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"
response <- VERB("GET", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.get('/baseUrl/legal_entities/:legal_entity_id/administrations/:id') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id";
let client = reqwest::Client::new();
let response = client.get(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request GET \
--url {{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id
http GET {{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id
wget --quiet \
--method GET \
--output-document \
- {{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "GET"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
PATCH
Update Administration
{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id
QUERY PARAMS
legal_entity_id
id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "PATCH");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/patch "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
require "http/client"
url = "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"
response = HTTP::Client.patch url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Patch,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id");
var request = new RestRequest("", Method.Patch);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"
req, _ := http.NewRequest("PATCH", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
PATCH /baseUrl/legal_entities/:legal_entity_id/administrations/:id HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("PATCH", "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"))
.method("PATCH", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
.patch(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.patch("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('PATCH', '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'PATCH',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id';
const options = {method: 'PATCH'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id',
method: 'PATCH',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
.patch(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'PATCH',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:legal_entity_id/administrations/:id',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'PATCH',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('PATCH', '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'PATCH',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id';
const options = {method: 'PATCH'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"PATCH"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id" in
Client.call `PATCH uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('PATCH', '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
$request->setMethod(HttpRequest::HTTP_METH_PATCH);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id');
$request->setRequestMethod('PATCH');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id' -Method PATCH
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id' -Method PATCH
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("PATCH", "/baseUrl/legal_entities/:legal_entity_id/administrations/:id")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"
response = requests.patch(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id"
response <- VERB("PATCH", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.patch('/baseUrl/legal_entities/:legal_entity_id/administrations/:id') do |req|
end
puts response.status
puts response.body
use std::str::FromStr;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id";
let client = reqwest::Client::new();
let response = client.request(reqwest::Method::from_str("PATCH").unwrap(), url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request PATCH \
--url {{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id
http PATCH {{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id
wget --quiet \
--method PATCH \
--output-document \
- {{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:legal_entity_id/administrations/:id")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "PATCH"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
GET
Discover Country Identifiers -- EXPERIMENTAL
{{baseUrl}}/discovery/identifiers
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/discovery/identifiers");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/get "{{baseUrl}}/discovery/identifiers")
require "http/client"
url = "{{baseUrl}}/discovery/identifiers"
response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("{{baseUrl}}/discovery/identifiers"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/discovery/identifiers");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/discovery/identifiers"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /baseUrl/discovery/identifiers HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/discovery/identifiers")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/discovery/identifiers"))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/discovery/identifiers")
.get()
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/discovery/identifiers")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('GET', '{{baseUrl}}/discovery/identifiers');
xhr.send(data);
import axios from 'axios';
const options = {method: 'GET', url: '{{baseUrl}}/discovery/identifiers'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/discovery/identifiers';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/discovery/identifiers',
method: 'GET',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/discovery/identifiers")
.get()
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'GET',
hostname: 'example.com',
port: null,
path: '/baseUrl/discovery/identifiers',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {method: 'GET', url: '{{baseUrl}}/discovery/identifiers'};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('GET', '{{baseUrl}}/discovery/identifiers');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {method: 'GET', url: '{{baseUrl}}/discovery/identifiers'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/discovery/identifiers';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/discovery/identifiers"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/discovery/identifiers" in
Client.call `GET uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/discovery/identifiers",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('GET', '{{baseUrl}}/discovery/identifiers');
echo $response->getBody();
setUrl('{{baseUrl}}/discovery/identifiers');
$request->setMethod(HTTP_METH_GET);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/discovery/identifiers');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/discovery/identifiers' -Method GET
$response = Invoke-RestMethod -Uri '{{baseUrl}}/discovery/identifiers' -Method GET
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("GET", "/baseUrl/discovery/identifiers")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/discovery/identifiers"
response = requests.get(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/discovery/identifiers"
response <- VERB("GET", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/discovery/identifiers")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.get('/baseUrl/discovery/identifiers') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/discovery/identifiers";
let client = reqwest::Client::new();
let response = client.get(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request GET \
--url {{baseUrl}}/discovery/identifiers
http GET {{baseUrl}}/discovery/identifiers
wget --quiet \
--method GET \
--output-document \
- {{baseUrl}}/discovery/identifiers
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/discovery/identifiers")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "GET"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
POST
Discover Network Participant Existence
{{baseUrl}}/discovery/exists
BODY json
{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/discovery/exists");
struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);
curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/post "{{baseUrl}}/discovery/exists" {:content-type :json
:form-params {:documentTypes []
:identifier ""
:metaScheme ""
:network ""
:scheme ""}})
require "http/client"
url = "{{baseUrl}}/discovery/exists"
headers = HTTP::Headers{
"content-type" => "application/json"
}
reqBody = "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}"
response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("{{baseUrl}}/discovery/exists"),
Content = new StringContent("{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/discovery/exists");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/discovery/exists"
payload := strings.NewReader("{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /baseUrl/discovery/exists HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 98
{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/discovery/exists")
.setHeader("content-type", "application/json")
.setBody("{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/discovery/exists"))
.header("content-type", "application/json")
.method("POST", HttpRequest.BodyPublishers.ofString("{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}"))
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}");
Request request = new Request.Builder()
.url("{{baseUrl}}/discovery/exists")
.post(body)
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/discovery/exists")
.header("content-type", "application/json")
.body("{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}")
.asString();
const data = JSON.stringify({
documentTypes: [],
identifier: '',
metaScheme: '',
network: '',
scheme: ''
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('POST', '{{baseUrl}}/discovery/exists');
xhr.setRequestHeader('content-type', 'application/json');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'POST',
url: '{{baseUrl}}/discovery/exists',
headers: {'content-type': 'application/json'},
data: {documentTypes: [], identifier: '', metaScheme: '', network: '', scheme: ''}
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/discovery/exists';
const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: '{"documentTypes":[],"identifier":"","metaScheme":"","network":"","scheme":""}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/discovery/exists',
method: 'POST',
headers: {
'content-type': 'application/json'
},
processData: false,
data: '{\n "documentTypes": [],\n "identifier": "",\n "metaScheme": "",\n "network": "",\n "scheme": ""\n}'
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}")
val request = Request.Builder()
.url("{{baseUrl}}/discovery/exists")
.post(body)
.addHeader("content-type", "application/json")
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'POST',
hostname: 'example.com',
port: null,
path: '/baseUrl/discovery/exists',
headers: {
'content-type': 'application/json'
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({documentTypes: [], identifier: '', metaScheme: '', network: '', scheme: ''}));
req.end();
const request = require('request');
const options = {
method: 'POST',
url: '{{baseUrl}}/discovery/exists',
headers: {'content-type': 'application/json'},
body: {documentTypes: [], identifier: '', metaScheme: '', network: '', scheme: ''},
json: true
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('POST', '{{baseUrl}}/discovery/exists');
req.headers({
'content-type': 'application/json'
});
req.type('json');
req.send({
documentTypes: [],
identifier: '',
metaScheme: '',
network: '',
scheme: ''
});
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'POST',
url: '{{baseUrl}}/discovery/exists',
headers: {'content-type': 'application/json'},
data: {documentTypes: [], identifier: '', metaScheme: '', network: '', scheme: ''}
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/discovery/exists';
const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: '{"documentTypes":[],"identifier":"","metaScheme":"","network":"","scheme":""}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"documentTypes": @[ ],
@"identifier": @"",
@"metaScheme": @"",
@"network": @"",
@"scheme": @"" };
NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/discovery/exists"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/discovery/exists" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}" in
Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/discovery/exists",
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([
'documentTypes' => [
],
'identifier' => '',
'metaScheme' => '',
'network' => '',
'scheme' => ''
]),
CURLOPT_HTTPHEADER => [
"content-type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('POST', '{{baseUrl}}/discovery/exists', [
'body' => '{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}',
'headers' => [
'content-type' => 'application/json',
],
]);
echo $response->getBody();
setUrl('{{baseUrl}}/discovery/exists');
$request->setMethod(HTTP_METH_POST);
$request->setHeaders([
'content-type' => 'application/json'
]);
$request->setContentType('application/json');
$request->setBody(json_encode([
'documentTypes' => [
],
'identifier' => '',
'metaScheme' => '',
'network' => '',
'scheme' => ''
]));
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
append(json_encode([
'documentTypes' => [
],
'identifier' => '',
'metaScheme' => '',
'network' => '',
'scheme' => ''
]));
$request->setRequestUrl('{{baseUrl}}/discovery/exists');
$request->setRequestMethod('POST');
$request->setBody($body);
$request->setHeaders([
'content-type' => 'application/json'
]);
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/discovery/exists' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/discovery/exists' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}'
import http.client
conn = http.client.HTTPSConnection("example.com")
payload = "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}"
headers = { 'content-type': "application/json" }
conn.request("POST", "/baseUrl/discovery/exists", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/discovery/exists"
payload = {
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}
headers = {"content-type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.json())
library(httr)
url <- "{{baseUrl}}/discovery/exists"
payload <- "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}"
encode <- "json"
response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/discovery/exists")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}"
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
headers: {'Content-Type' => 'application/json'}
)
response = conn.post('/baseUrl/discovery/exists') do |req|
req.body = "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}"
end
puts response.status
puts response.body
use serde_json::json;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/discovery/exists";
let payload = json!({
"documentTypes": (),
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
});
let mut headers = reqwest::header::HeaderMap::new();
headers.insert("content-type", "application/json".parse().unwrap());
let client = reqwest::Client::new();
let response = client.post(url)
.headers(headers)
.json(&payload)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request POST \
--url {{baseUrl}}/discovery/exists \
--header 'content-type: application/json' \
--data '{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}'
echo '{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}' | \
http POST {{baseUrl}}/discovery/exists \
content-type:application/json
wget --quiet \
--method POST \
--header 'content-type: application/json' \
--body-data '{\n "documentTypes": [],\n "identifier": "",\n "metaScheme": "",\n "network": "",\n "scheme": ""\n}' \
--output-document \
- {{baseUrl}}/discovery/exists
import Foundation
let headers = ["content-type": "application/json"]
let parameters = [
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
] as [String : Any]
let postData = JSONSerialization.data(withJSONObject: parameters, options: [])
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/discovery/exists")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
POST
Disover Network Participant
{{baseUrl}}/discovery/receives
BODY json
{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/discovery/receives");
struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);
curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/post "{{baseUrl}}/discovery/receives" {:content-type :json
:form-params {:documentTypes []
:identifier ""
:metaScheme ""
:network ""
:scheme ""}})
require "http/client"
url = "{{baseUrl}}/discovery/receives"
headers = HTTP::Headers{
"content-type" => "application/json"
}
reqBody = "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}"
response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("{{baseUrl}}/discovery/receives"),
Content = new StringContent("{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/discovery/receives");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/discovery/receives"
payload := strings.NewReader("{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /baseUrl/discovery/receives HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 98
{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/discovery/receives")
.setHeader("content-type", "application/json")
.setBody("{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/discovery/receives"))
.header("content-type", "application/json")
.method("POST", HttpRequest.BodyPublishers.ofString("{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}"))
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}");
Request request = new Request.Builder()
.url("{{baseUrl}}/discovery/receives")
.post(body)
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/discovery/receives")
.header("content-type", "application/json")
.body("{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}")
.asString();
const data = JSON.stringify({
documentTypes: [],
identifier: '',
metaScheme: '',
network: '',
scheme: ''
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('POST', '{{baseUrl}}/discovery/receives');
xhr.setRequestHeader('content-type', 'application/json');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'POST',
url: '{{baseUrl}}/discovery/receives',
headers: {'content-type': 'application/json'},
data: {documentTypes: [], identifier: '', metaScheme: '', network: '', scheme: ''}
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/discovery/receives';
const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: '{"documentTypes":[],"identifier":"","metaScheme":"","network":"","scheme":""}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/discovery/receives',
method: 'POST',
headers: {
'content-type': 'application/json'
},
processData: false,
data: '{\n "documentTypes": [],\n "identifier": "",\n "metaScheme": "",\n "network": "",\n "scheme": ""\n}'
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}")
val request = Request.Builder()
.url("{{baseUrl}}/discovery/receives")
.post(body)
.addHeader("content-type", "application/json")
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'POST',
hostname: 'example.com',
port: null,
path: '/baseUrl/discovery/receives',
headers: {
'content-type': 'application/json'
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({documentTypes: [], identifier: '', metaScheme: '', network: '', scheme: ''}));
req.end();
const request = require('request');
const options = {
method: 'POST',
url: '{{baseUrl}}/discovery/receives',
headers: {'content-type': 'application/json'},
body: {documentTypes: [], identifier: '', metaScheme: '', network: '', scheme: ''},
json: true
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('POST', '{{baseUrl}}/discovery/receives');
req.headers({
'content-type': 'application/json'
});
req.type('json');
req.send({
documentTypes: [],
identifier: '',
metaScheme: '',
network: '',
scheme: ''
});
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'POST',
url: '{{baseUrl}}/discovery/receives',
headers: {'content-type': 'application/json'},
data: {documentTypes: [], identifier: '', metaScheme: '', network: '', scheme: ''}
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/discovery/receives';
const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: '{"documentTypes":[],"identifier":"","metaScheme":"","network":"","scheme":""}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"documentTypes": @[ ],
@"identifier": @"",
@"metaScheme": @"",
@"network": @"",
@"scheme": @"" };
NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/discovery/receives"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/discovery/receives" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}" in
Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/discovery/receives",
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([
'documentTypes' => [
],
'identifier' => '',
'metaScheme' => '',
'network' => '',
'scheme' => ''
]),
CURLOPT_HTTPHEADER => [
"content-type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('POST', '{{baseUrl}}/discovery/receives', [
'body' => '{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}',
'headers' => [
'content-type' => 'application/json',
],
]);
echo $response->getBody();
setUrl('{{baseUrl}}/discovery/receives');
$request->setMethod(HTTP_METH_POST);
$request->setHeaders([
'content-type' => 'application/json'
]);
$request->setContentType('application/json');
$request->setBody(json_encode([
'documentTypes' => [
],
'identifier' => '',
'metaScheme' => '',
'network' => '',
'scheme' => ''
]));
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
append(json_encode([
'documentTypes' => [
],
'identifier' => '',
'metaScheme' => '',
'network' => '',
'scheme' => ''
]));
$request->setRequestUrl('{{baseUrl}}/discovery/receives');
$request->setRequestMethod('POST');
$request->setBody($body);
$request->setHeaders([
'content-type' => 'application/json'
]);
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/discovery/receives' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/discovery/receives' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}'
import http.client
conn = http.client.HTTPSConnection("example.com")
payload = "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}"
headers = { 'content-type': "application/json" }
conn.request("POST", "/baseUrl/discovery/receives", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/discovery/receives"
payload = {
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}
headers = {"content-type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.json())
library(httr)
url <- "{{baseUrl}}/discovery/receives"
payload <- "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}"
encode <- "json"
response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/discovery/receives")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}"
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
headers: {'Content-Type' => 'application/json'}
)
response = conn.post('/baseUrl/discovery/receives') do |req|
req.body = "{\n \"documentTypes\": [],\n \"identifier\": \"\",\n \"metaScheme\": \"\",\n \"network\": \"\",\n \"scheme\": \"\"\n}"
end
puts response.status
puts response.body
use serde_json::json;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/discovery/receives";
let payload = json!({
"documentTypes": (),
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
});
let mut headers = reqwest::header::HeaderMap::new();
headers.insert("content-type", "application/json".parse().unwrap());
let client = reqwest::Client::new();
let response = client.post(url)
.headers(headers)
.json(&payload)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request POST \
--url {{baseUrl}}/discovery/receives \
--header 'content-type: application/json' \
--data '{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}'
echo '{
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
}' | \
http POST {{baseUrl}}/discovery/receives \
content-type:application/json
wget --quiet \
--method POST \
--header 'content-type: application/json' \
--body-data '{\n "documentTypes": [],\n "identifier": "",\n "metaScheme": "",\n "network": "",\n "scheme": ""\n}' \
--output-document \
- {{baseUrl}}/discovery/receives
import Foundation
let headers = ["content-type": "application/json"]
let parameters = [
"documentTypes": [],
"identifier": "",
"metaScheme": "",
"network": "",
"scheme": ""
] as [String : Any]
let postData = JSONSerialization.data(withJSONObject: parameters, options: [])
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/discovery/receives")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
GET
Get DocumentSubmission Evidence
{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type
QUERY PARAMS
guid
evidence_type
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/get "{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type")
require "http/client"
url = "{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type"
response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /baseUrl/document_submissions/:guid/evidence/:evidence_type HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type"))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type")
.get()
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('GET', '{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'GET',
url: '{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type',
method: 'GET',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type")
.get()
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'GET',
hostname: 'example.com',
port: null,
path: '/baseUrl/document_submissions/:guid/evidence/:evidence_type',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'GET',
url: '{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('GET', '{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'GET',
url: '{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type" in
Client.call `GET uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('GET', '{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type');
echo $response->getBody();
setUrl('{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type');
$request->setMethod(HTTP_METH_GET);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type' -Method GET
$response = Invoke-RestMethod -Uri '{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type' -Method GET
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("GET", "/baseUrl/document_submissions/:guid/evidence/:evidence_type")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type"
response = requests.get(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type"
response <- VERB("GET", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.get('/baseUrl/document_submissions/:guid/evidence/:evidence_type') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type";
let client = reqwest::Client::new();
let response = client.get(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request GET \
--url {{baseUrl}}/document_submissions/:guid/evidence/:evidence_type
http GET {{baseUrl}}/document_submissions/:guid/evidence/:evidence_type
wget --quiet \
--method GET \
--output-document \
- {{baseUrl}}/document_submissions/:guid/evidence/:evidence_type
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/document_submissions/:guid/evidence/:evidence_type")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "GET"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
POST
Submit a new document.
{{baseUrl}}/document_submissions
BODY json
{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": {
"documentType": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceResponse": {
"clarifications": [
{
"clarification": "",
"clarificationCode": "",
"clarificationCodeType": "",
"conditions": [
{
"fieldCode": "",
"fieldValue": ""
}
]
}
],
"effectiveDate": "",
"note": "",
"responseCode": ""
},
"order": {
"accountingCost": "",
"allowanceCharges": [
{}
],
"amountIncludingTax": "",
"attachments": [
{}
],
"delivery": {},
"deliveryTerms": {
"deliveryLocationId": "",
"incoterms": "",
"specialTerms": ""
},
"documentCurrencyCode": "",
"documentNumber": "",
"issueDate": "",
"issueTime": "",
"note": "",
"orderLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{}
],
"allowPartialDelivery": false,
"allowanceCharges": [
{}
],
"amountExcludingTax": "",
"baseQuantity": "",
"delivery": {
"deliveryLocation": {
"id": "",
"schemeId": ""
}
},
"description": "",
"itemPrice": "",
"lineId": "",
"lotNumberIds": [],
"name": "",
"note": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{}
],
"taxesDutiesFees": [
{}
]
}
],
"orderType": "",
"paymentTerms": {},
"references": [
{}
],
"sellerSupplierParty": {
"party": {},
"publicIdentifiers": [
{}
]
},
"taxSystem": "",
"timeZone": "",
"validityPeriod": ""
},
"rawDocumentData": {
"document": "",
"documentTypeId": "",
"parse": false,
"parseStrategy": "",
"processId": ""
}
},
"idempotencyGuid": "",
"legalEntityId": 0,
"receiveGuid": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
}
}
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/document_submissions");
struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);
curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/post "{{baseUrl}}/document_submissions" {:content-type :json
:form-params {:attachments [{:description ""
:document ""
:documentId ""
:filename ""
:mimeType ""
:primaryImage false}]
:createPrimaryImage false
:document {:documentType ""
:invoice {:accountingCost ""
:accountingCurrencyTaxAmount ""
:accountingCurrencyTaxAmountCurrency ""
:accountingCustomerParty {:party {:address {:city ""
:country ""
:county ""
:street1 ""
:street2 ""
:zip ""}
:companyName ""
:contact {:email ""
:firstName ""
:id ""
:lastName ""
:phone ""}}
:publicIdentifiers [{:id ""
:scheme ""}]}
:accountingSupplierParty {:party {:contact {}}}
:allowanceCharges [{:amountExcludingTax ""
:amountExcludingVat ""
:amountIncludingTax ""
:baseAmountExcludingTax ""
:baseAmountIncludingTax ""
:reason ""
:reasonCode ""
:tax {:amount ""
:category ""
:country ""
:percentage ""}
:taxesDutiesFees [{}]}]
:amountIncludingVat ""
:attachments [{}]
:billingReference ""
:buyerReference ""
:consumerTaxMode false
:contractDocumentReference ""
:delivery {:actualDate ""
:deliveryLocation {:address {}
:id ""
:locationName ""
:schemeAgencyId ""
:schemeId ""}
:deliveryParty {:party {}}
:deliveryPartyName ""
:quantity ""
:requestedDeliveryPeriod ""
:shippingMarks ""}
:documentCurrencyCode ""
:dueDate ""
:invoiceLines [{:accountingCost ""
:additionalItemProperties [{:name ""
:value ""}]
:allowanceCharge ""
:allowanceCharges [{:amountExcludingTax ""
:baseAmountExcludingTax ""
:reason ""
:reasonCode ""}]
:amountExcludingTax ""
:amountExcludingVat ""
:amountIncludingTax ""
:buyersItemIdentification ""
:description ""
:invoicePeriod ""
:itemPrice ""
:lineId ""
:name ""
:note ""
:orderLineReferenceLineId ""
:quantity ""
:quantityUnitCode ""
:references [{:documentId ""
:documentType ""
:issueDate ""
:lineId ""}]
:sellersItemIdentification ""
:standardItemIdentification ""
:standardItemIdentificationSchemeAgencyId ""
:standardItemIdentificationSchemeId ""
:tax {}
:taxesDutiesFees [{}]}]
:invoiceNumber ""
:invoicePeriod ""
:invoiceType ""
:issueDate ""
:issueReasons []
:note ""
:orderReference ""
:paymentMeansArray [{:account ""
:amount ""
:branche_code ""
:code ""
:holder ""
:mandate ""
:network ""
:paymentId ""}]
:paymentMeansBic ""
:paymentMeansCode ""
:paymentMeansIban ""
:paymentMeansPaymentId ""
:paymentTerms {:note ""}
:preferredInvoiceType ""
:prepaidAmount ""
:priceMode ""
:projectReference ""
:references [{}]
:salesOrderId ""
:selfBillingMode false
:taxExemptReason ""
:taxPointDate ""
:taxSubtotals [{:category ""
:country ""
:percentage ""
:taxAmount ""
:taxableAmount ""}]
:taxSystem ""
:taxesDutiesFees [{}]
:transactionType ""
:ublExtensions []
:vatReverseCharge false
:x2y ""}
:invoiceResponse {:clarifications [{:clarification ""
:clarificationCode ""
:clarificationCodeType ""
:conditions [{:fieldCode ""
:fieldValue ""}]}]
:effectiveDate ""
:note ""
:responseCode ""}
:order {:accountingCost ""
:allowanceCharges [{}]
:amountIncludingTax ""
:attachments [{}]
:delivery {}
:deliveryTerms {:deliveryLocationId ""
:incoterms ""
:specialTerms ""}
:documentCurrencyCode ""
:documentNumber ""
:issueDate ""
:issueTime ""
:note ""
:orderLines [{:accountingCost ""
:additionalItemProperties [{}]
:allowPartialDelivery false
:allowanceCharges [{}]
:amountExcludingTax ""
:baseQuantity ""
:delivery {:deliveryLocation {:id ""
:schemeId ""}}
:description ""
:itemPrice ""
:lineId ""
:lotNumberIds []
:name ""
:note ""
:quantity ""
:quantityUnitCode ""
:references [{}]
:taxesDutiesFees [{}]}]
:orderType ""
:paymentTerms {}
:references [{}]
:sellerSupplierParty {:party {}
:publicIdentifiers [{}]}
:taxSystem ""
:timeZone ""
:validityPeriod ""}
:rawDocumentData {:document ""
:documentTypeId ""
:parse false
:parseStrategy ""
:processId ""}}
:idempotencyGuid ""
:legalEntityId 0
:receiveGuid ""
:routing {:clearWithoutSending false
:eIdentifiers [{:id ""
:scheme ""}]
:emails []}}})
require "http/client"
url = "{{baseUrl}}/document_submissions"
headers = HTTP::Headers{
"content-type" => "application/json"
}
reqBody = "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}"
response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("{{baseUrl}}/document_submissions"),
Content = new StringContent("{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/document_submissions");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/document_submissions"
payload := strings.NewReader("{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /baseUrl/document_submissions HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 7080
{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": {
"documentType": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceResponse": {
"clarifications": [
{
"clarification": "",
"clarificationCode": "",
"clarificationCodeType": "",
"conditions": [
{
"fieldCode": "",
"fieldValue": ""
}
]
}
],
"effectiveDate": "",
"note": "",
"responseCode": ""
},
"order": {
"accountingCost": "",
"allowanceCharges": [
{}
],
"amountIncludingTax": "",
"attachments": [
{}
],
"delivery": {},
"deliveryTerms": {
"deliveryLocationId": "",
"incoterms": "",
"specialTerms": ""
},
"documentCurrencyCode": "",
"documentNumber": "",
"issueDate": "",
"issueTime": "",
"note": "",
"orderLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{}
],
"allowPartialDelivery": false,
"allowanceCharges": [
{}
],
"amountExcludingTax": "",
"baseQuantity": "",
"delivery": {
"deliveryLocation": {
"id": "",
"schemeId": ""
}
},
"description": "",
"itemPrice": "",
"lineId": "",
"lotNumberIds": [],
"name": "",
"note": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{}
],
"taxesDutiesFees": [
{}
]
}
],
"orderType": "",
"paymentTerms": {},
"references": [
{}
],
"sellerSupplierParty": {
"party": {},
"publicIdentifiers": [
{}
]
},
"taxSystem": "",
"timeZone": "",
"validityPeriod": ""
},
"rawDocumentData": {
"document": "",
"documentTypeId": "",
"parse": false,
"parseStrategy": "",
"processId": ""
}
},
"idempotencyGuid": "",
"legalEntityId": 0,
"receiveGuid": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
}
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/document_submissions")
.setHeader("content-type", "application/json")
.setBody("{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/document_submissions"))
.header("content-type", "application/json")
.method("POST", HttpRequest.BodyPublishers.ofString("{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}"))
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}");
Request request = new Request.Builder()
.url("{{baseUrl}}/document_submissions")
.post(body)
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/document_submissions")
.header("content-type", "application/json")
.body("{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}")
.asString();
const data = JSON.stringify({
attachments: [
{
description: '',
document: '',
documentId: '',
filename: '',
mimeType: '',
primaryImage: false
}
],
createPrimaryImage: false,
document: {
documentType: '',
invoice: {
accountingCost: '',
accountingCurrencyTaxAmount: '',
accountingCurrencyTaxAmountCurrency: '',
accountingCustomerParty: {
party: {
address: {
city: '',
country: '',
county: '',
street1: '',
street2: '',
zip: ''
},
companyName: '',
contact: {
email: '',
firstName: '',
id: '',
lastName: '',
phone: ''
}
},
publicIdentifiers: [
{
id: '',
scheme: ''
}
]
},
accountingSupplierParty: {
party: {
contact: {}
}
},
allowanceCharges: [
{
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
baseAmountExcludingTax: '',
baseAmountIncludingTax: '',
reason: '',
reasonCode: '',
tax: {
amount: '',
category: '',
country: '',
percentage: ''
},
taxesDutiesFees: [
{}
]
}
],
amountIncludingVat: '',
attachments: [
{}
],
billingReference: '',
buyerReference: '',
consumerTaxMode: false,
contractDocumentReference: '',
delivery: {
actualDate: '',
deliveryLocation: {
address: {},
id: '',
locationName: '',
schemeAgencyId: '',
schemeId: ''
},
deliveryParty: {
party: {}
},
deliveryPartyName: '',
quantity: '',
requestedDeliveryPeriod: '',
shippingMarks: ''
},
documentCurrencyCode: '',
dueDate: '',
invoiceLines: [
{
accountingCost: '',
additionalItemProperties: [
{
name: '',
value: ''
}
],
allowanceCharge: '',
allowanceCharges: [
{
amountExcludingTax: '',
baseAmountExcludingTax: '',
reason: '',
reasonCode: ''
}
],
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
buyersItemIdentification: '',
description: '',
invoicePeriod: '',
itemPrice: '',
lineId: '',
name: '',
note: '',
orderLineReferenceLineId: '',
quantity: '',
quantityUnitCode: '',
references: [
{
documentId: '',
documentType: '',
issueDate: '',
lineId: ''
}
],
sellersItemIdentification: '',
standardItemIdentification: '',
standardItemIdentificationSchemeAgencyId: '',
standardItemIdentificationSchemeId: '',
tax: {},
taxesDutiesFees: [
{}
]
}
],
invoiceNumber: '',
invoicePeriod: '',
invoiceType: '',
issueDate: '',
issueReasons: [],
note: '',
orderReference: '',
paymentMeansArray: [
{
account: '',
amount: '',
branche_code: '',
code: '',
holder: '',
mandate: '',
network: '',
paymentId: ''
}
],
paymentMeansBic: '',
paymentMeansCode: '',
paymentMeansIban: '',
paymentMeansPaymentId: '',
paymentTerms: {
note: ''
},
preferredInvoiceType: '',
prepaidAmount: '',
priceMode: '',
projectReference: '',
references: [
{}
],
salesOrderId: '',
selfBillingMode: false,
taxExemptReason: '',
taxPointDate: '',
taxSubtotals: [
{
category: '',
country: '',
percentage: '',
taxAmount: '',
taxableAmount: ''
}
],
taxSystem: '',
taxesDutiesFees: [
{}
],
transactionType: '',
ublExtensions: [],
vatReverseCharge: false,
x2y: ''
},
invoiceResponse: {
clarifications: [
{
clarification: '',
clarificationCode: '',
clarificationCodeType: '',
conditions: [
{
fieldCode: '',
fieldValue: ''
}
]
}
],
effectiveDate: '',
note: '',
responseCode: ''
},
order: {
accountingCost: '',
allowanceCharges: [
{}
],
amountIncludingTax: '',
attachments: [
{}
],
delivery: {},
deliveryTerms: {
deliveryLocationId: '',
incoterms: '',
specialTerms: ''
},
documentCurrencyCode: '',
documentNumber: '',
issueDate: '',
issueTime: '',
note: '',
orderLines: [
{
accountingCost: '',
additionalItemProperties: [
{}
],
allowPartialDelivery: false,
allowanceCharges: [
{}
],
amountExcludingTax: '',
baseQuantity: '',
delivery: {
deliveryLocation: {
id: '',
schemeId: ''
}
},
description: '',
itemPrice: '',
lineId: '',
lotNumberIds: [],
name: '',
note: '',
quantity: '',
quantityUnitCode: '',
references: [
{}
],
taxesDutiesFees: [
{}
]
}
],
orderType: '',
paymentTerms: {},
references: [
{}
],
sellerSupplierParty: {
party: {},
publicIdentifiers: [
{}
]
},
taxSystem: '',
timeZone: '',
validityPeriod: ''
},
rawDocumentData: {
document: '',
documentTypeId: '',
parse: false,
parseStrategy: '',
processId: ''
}
},
idempotencyGuid: '',
legalEntityId: 0,
receiveGuid: '',
routing: {
clearWithoutSending: false,
eIdentifiers: [
{
id: '',
scheme: ''
}
],
emails: []
}
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('POST', '{{baseUrl}}/document_submissions');
xhr.setRequestHeader('content-type', 'application/json');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'POST',
url: '{{baseUrl}}/document_submissions',
headers: {'content-type': 'application/json'},
data: {
attachments: [
{
description: '',
document: '',
documentId: '',
filename: '',
mimeType: '',
primaryImage: false
}
],
createPrimaryImage: false,
document: {
documentType: '',
invoice: {
accountingCost: '',
accountingCurrencyTaxAmount: '',
accountingCurrencyTaxAmountCurrency: '',
accountingCustomerParty: {
party: {
address: {city: '', country: '', county: '', street1: '', street2: '', zip: ''},
companyName: '',
contact: {email: '', firstName: '', id: '', lastName: '', phone: ''}
},
publicIdentifiers: [{id: '', scheme: ''}]
},
accountingSupplierParty: {party: {contact: {}}},
allowanceCharges: [
{
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
baseAmountExcludingTax: '',
baseAmountIncludingTax: '',
reason: '',
reasonCode: '',
tax: {amount: '', category: '', country: '', percentage: ''},
taxesDutiesFees: [{}]
}
],
amountIncludingVat: '',
attachments: [{}],
billingReference: '',
buyerReference: '',
consumerTaxMode: false,
contractDocumentReference: '',
delivery: {
actualDate: '',
deliveryLocation: {address: {}, id: '', locationName: '', schemeAgencyId: '', schemeId: ''},
deliveryParty: {party: {}},
deliveryPartyName: '',
quantity: '',
requestedDeliveryPeriod: '',
shippingMarks: ''
},
documentCurrencyCode: '',
dueDate: '',
invoiceLines: [
{
accountingCost: '',
additionalItemProperties: [{name: '', value: ''}],
allowanceCharge: '',
allowanceCharges: [
{amountExcludingTax: '', baseAmountExcludingTax: '', reason: '', reasonCode: ''}
],
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
buyersItemIdentification: '',
description: '',
invoicePeriod: '',
itemPrice: '',
lineId: '',
name: '',
note: '',
orderLineReferenceLineId: '',
quantity: '',
quantityUnitCode: '',
references: [{documentId: '', documentType: '', issueDate: '', lineId: ''}],
sellersItemIdentification: '',
standardItemIdentification: '',
standardItemIdentificationSchemeAgencyId: '',
standardItemIdentificationSchemeId: '',
tax: {},
taxesDutiesFees: [{}]
}
],
invoiceNumber: '',
invoicePeriod: '',
invoiceType: '',
issueDate: '',
issueReasons: [],
note: '',
orderReference: '',
paymentMeansArray: [
{
account: '',
amount: '',
branche_code: '',
code: '',
holder: '',
mandate: '',
network: '',
paymentId: ''
}
],
paymentMeansBic: '',
paymentMeansCode: '',
paymentMeansIban: '',
paymentMeansPaymentId: '',
paymentTerms: {note: ''},
preferredInvoiceType: '',
prepaidAmount: '',
priceMode: '',
projectReference: '',
references: [{}],
salesOrderId: '',
selfBillingMode: false,
taxExemptReason: '',
taxPointDate: '',
taxSubtotals: [{category: '', country: '', percentage: '', taxAmount: '', taxableAmount: ''}],
taxSystem: '',
taxesDutiesFees: [{}],
transactionType: '',
ublExtensions: [],
vatReverseCharge: false,
x2y: ''
},
invoiceResponse: {
clarifications: [
{
clarification: '',
clarificationCode: '',
clarificationCodeType: '',
conditions: [{fieldCode: '', fieldValue: ''}]
}
],
effectiveDate: '',
note: '',
responseCode: ''
},
order: {
accountingCost: '',
allowanceCharges: [{}],
amountIncludingTax: '',
attachments: [{}],
delivery: {},
deliveryTerms: {deliveryLocationId: '', incoterms: '', specialTerms: ''},
documentCurrencyCode: '',
documentNumber: '',
issueDate: '',
issueTime: '',
note: '',
orderLines: [
{
accountingCost: '',
additionalItemProperties: [{}],
allowPartialDelivery: false,
allowanceCharges: [{}],
amountExcludingTax: '',
baseQuantity: '',
delivery: {deliveryLocation: {id: '', schemeId: ''}},
description: '',
itemPrice: '',
lineId: '',
lotNumberIds: [],
name: '',
note: '',
quantity: '',
quantityUnitCode: '',
references: [{}],
taxesDutiesFees: [{}]
}
],
orderType: '',
paymentTerms: {},
references: [{}],
sellerSupplierParty: {party: {}, publicIdentifiers: [{}]},
taxSystem: '',
timeZone: '',
validityPeriod: ''
},
rawDocumentData: {
document: '',
documentTypeId: '',
parse: false,
parseStrategy: '',
processId: ''
}
},
idempotencyGuid: '',
legalEntityId: 0,
receiveGuid: '',
routing: {clearWithoutSending: false, eIdentifiers: [{id: '', scheme: ''}], emails: []}
}
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/document_submissions';
const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: '{"attachments":[{"description":"","document":"","documentId":"","filename":"","mimeType":"","primaryImage":false}],"createPrimaryImage":false,"document":{"documentType":"","invoice":{"accountingCost":"","accountingCurrencyTaxAmount":"","accountingCurrencyTaxAmountCurrency":"","accountingCustomerParty":{"party":{"address":{"city":"","country":"","county":"","street1":"","street2":"","zip":""},"companyName":"","contact":{"email":"","firstName":"","id":"","lastName":"","phone":""}},"publicIdentifiers":[{"id":"","scheme":""}]},"accountingSupplierParty":{"party":{"contact":{}}},"allowanceCharges":[{"amountExcludingTax":"","amountExcludingVat":"","amountIncludingTax":"","baseAmountExcludingTax":"","baseAmountIncludingTax":"","reason":"","reasonCode":"","tax":{"amount":"","category":"","country":"","percentage":""},"taxesDutiesFees":[{}]}],"amountIncludingVat":"","attachments":[{}],"billingReference":"","buyerReference":"","consumerTaxMode":false,"contractDocumentReference":"","delivery":{"actualDate":"","deliveryLocation":{"address":{},"id":"","locationName":"","schemeAgencyId":"","schemeId":""},"deliveryParty":{"party":{}},"deliveryPartyName":"","quantity":"","requestedDeliveryPeriod":"","shippingMarks":""},"documentCurrencyCode":"","dueDate":"","invoiceLines":[{"accountingCost":"","additionalItemProperties":[{"name":"","value":""}],"allowanceCharge":"","allowanceCharges":[{"amountExcludingTax":"","baseAmountExcludingTax":"","reason":"","reasonCode":""}],"amountExcludingTax":"","amountExcludingVat":"","amountIncludingTax":"","buyersItemIdentification":"","description":"","invoicePeriod":"","itemPrice":"","lineId":"","name":"","note":"","orderLineReferenceLineId":"","quantity":"","quantityUnitCode":"","references":[{"documentId":"","documentType":"","issueDate":"","lineId":""}],"sellersItemIdentification":"","standardItemIdentification":"","standardItemIdentificationSchemeAgencyId":"","standardItemIdentificationSchemeId":"","tax":{},"taxesDutiesFees":[{}]}],"invoiceNumber":"","invoicePeriod":"","invoiceType":"","issueDate":"","issueReasons":[],"note":"","orderReference":"","paymentMeansArray":[{"account":"","amount":"","branche_code":"","code":"","holder":"","mandate":"","network":"","paymentId":""}],"paymentMeansBic":"","paymentMeansCode":"","paymentMeansIban":"","paymentMeansPaymentId":"","paymentTerms":{"note":""},"preferredInvoiceType":"","prepaidAmount":"","priceMode":"","projectReference":"","references":[{}],"salesOrderId":"","selfBillingMode":false,"taxExemptReason":"","taxPointDate":"","taxSubtotals":[{"category":"","country":"","percentage":"","taxAmount":"","taxableAmount":""}],"taxSystem":"","taxesDutiesFees":[{}],"transactionType":"","ublExtensions":[],"vatReverseCharge":false,"x2y":""},"invoiceResponse":{"clarifications":[{"clarification":"","clarificationCode":"","clarificationCodeType":"","conditions":[{"fieldCode":"","fieldValue":""}]}],"effectiveDate":"","note":"","responseCode":""},"order":{"accountingCost":"","allowanceCharges":[{}],"amountIncludingTax":"","attachments":[{}],"delivery":{},"deliveryTerms":{"deliveryLocationId":"","incoterms":"","specialTerms":""},"documentCurrencyCode":"","documentNumber":"","issueDate":"","issueTime":"","note":"","orderLines":[{"accountingCost":"","additionalItemProperties":[{}],"allowPartialDelivery":false,"allowanceCharges":[{}],"amountExcludingTax":"","baseQuantity":"","delivery":{"deliveryLocation":{"id":"","schemeId":""}},"description":"","itemPrice":"","lineId":"","lotNumberIds":[],"name":"","note":"","quantity":"","quantityUnitCode":"","references":[{}],"taxesDutiesFees":[{}]}],"orderType":"","paymentTerms":{},"references":[{}],"sellerSupplierParty":{"party":{},"publicIdentifiers":[{}]},"taxSystem":"","timeZone":"","validityPeriod":""},"rawDocumentData":{"document":"","documentTypeId":"","parse":false,"parseStrategy":"","processId":""}},"idempotencyGuid":"","legalEntityId":0,"receiveGuid":"","routing":{"clearWithoutSending":false,"eIdentifiers":[{"id":"","scheme":""}],"emails":[]}}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/document_submissions',
method: 'POST',
headers: {
'content-type': 'application/json'
},
processData: false,
data: '{\n "attachments": [\n {\n "description": "",\n "document": "",\n "documentId": "",\n "filename": "",\n "mimeType": "",\n "primaryImage": false\n }\n ],\n "createPrimaryImage": false,\n "document": {\n "documentType": "",\n "invoice": {\n "accountingCost": "",\n "accountingCurrencyTaxAmount": "",\n "accountingCurrencyTaxAmountCurrency": "",\n "accountingCustomerParty": {\n "party": {\n "address": {\n "city": "",\n "country": "",\n "county": "",\n "street1": "",\n "street2": "",\n "zip": ""\n },\n "companyName": "",\n "contact": {\n "email": "",\n "firstName": "",\n "id": "",\n "lastName": "",\n "phone": ""\n }\n },\n "publicIdentifiers": [\n {\n "id": "",\n "scheme": ""\n }\n ]\n },\n "accountingSupplierParty": {\n "party": {\n "contact": {}\n }\n },\n "allowanceCharges": [\n {\n "amountExcludingTax": "",\n "amountExcludingVat": "",\n "amountIncludingTax": "",\n "baseAmountExcludingTax": "",\n "baseAmountIncludingTax": "",\n "reason": "",\n "reasonCode": "",\n "tax": {\n "amount": "",\n "category": "",\n "country": "",\n "percentage": ""\n },\n "taxesDutiesFees": [\n {}\n ]\n }\n ],\n "amountIncludingVat": "",\n "attachments": [\n {}\n ],\n "billingReference": "",\n "buyerReference": "",\n "consumerTaxMode": false,\n "contractDocumentReference": "",\n "delivery": {\n "actualDate": "",\n "deliveryLocation": {\n "address": {},\n "id": "",\n "locationName": "",\n "schemeAgencyId": "",\n "schemeId": ""\n },\n "deliveryParty": {\n "party": {}\n },\n "deliveryPartyName": "",\n "quantity": "",\n "requestedDeliveryPeriod": "",\n "shippingMarks": ""\n },\n "documentCurrencyCode": "",\n "dueDate": "",\n "invoiceLines": [\n {\n "accountingCost": "",\n "additionalItemProperties": [\n {\n "name": "",\n "value": ""\n }\n ],\n "allowanceCharge": "",\n "allowanceCharges": [\n {\n "amountExcludingTax": "",\n "baseAmountExcludingTax": "",\n "reason": "",\n "reasonCode": ""\n }\n ],\n "amountExcludingTax": "",\n "amountExcludingVat": "",\n "amountIncludingTax": "",\n "buyersItemIdentification": "",\n "description": "",\n "invoicePeriod": "",\n "itemPrice": "",\n "lineId": "",\n "name": "",\n "note": "",\n "orderLineReferenceLineId": "",\n "quantity": "",\n "quantityUnitCode": "",\n "references": [\n {\n "documentId": "",\n "documentType": "",\n "issueDate": "",\n "lineId": ""\n }\n ],\n "sellersItemIdentification": "",\n "standardItemIdentification": "",\n "standardItemIdentificationSchemeAgencyId": "",\n "standardItemIdentificationSchemeId": "",\n "tax": {},\n "taxesDutiesFees": [\n {}\n ]\n }\n ],\n "invoiceNumber": "",\n "invoicePeriod": "",\n "invoiceType": "",\n "issueDate": "",\n "issueReasons": [],\n "note": "",\n "orderReference": "",\n "paymentMeansArray": [\n {\n "account": "",\n "amount": "",\n "branche_code": "",\n "code": "",\n "holder": "",\n "mandate": "",\n "network": "",\n "paymentId": ""\n }\n ],\n "paymentMeansBic": "",\n "paymentMeansCode": "",\n "paymentMeansIban": "",\n "paymentMeansPaymentId": "",\n "paymentTerms": {\n "note": ""\n },\n "preferredInvoiceType": "",\n "prepaidAmount": "",\n "priceMode": "",\n "projectReference": "",\n "references": [\n {}\n ],\n "salesOrderId": "",\n "selfBillingMode": false,\n "taxExemptReason": "",\n "taxPointDate": "",\n "taxSubtotals": [\n {\n "category": "",\n "country": "",\n "percentage": "",\n "taxAmount": "",\n "taxableAmount": ""\n }\n ],\n "taxSystem": "",\n "taxesDutiesFees": [\n {}\n ],\n "transactionType": "",\n "ublExtensions": [],\n "vatReverseCharge": false,\n "x2y": ""\n },\n "invoiceResponse": {\n "clarifications": [\n {\n "clarification": "",\n "clarificationCode": "",\n "clarificationCodeType": "",\n "conditions": [\n {\n "fieldCode": "",\n "fieldValue": ""\n }\n ]\n }\n ],\n "effectiveDate": "",\n "note": "",\n "responseCode": ""\n },\n "order": {\n "accountingCost": "",\n "allowanceCharges": [\n {}\n ],\n "amountIncludingTax": "",\n "attachments": [\n {}\n ],\n "delivery": {},\n "deliveryTerms": {\n "deliveryLocationId": "",\n "incoterms": "",\n "specialTerms": ""\n },\n "documentCurrencyCode": "",\n "documentNumber": "",\n "issueDate": "",\n "issueTime": "",\n "note": "",\n "orderLines": [\n {\n "accountingCost": "",\n "additionalItemProperties": [\n {}\n ],\n "allowPartialDelivery": false,\n "allowanceCharges": [\n {}\n ],\n "amountExcludingTax": "",\n "baseQuantity": "",\n "delivery": {\n "deliveryLocation": {\n "id": "",\n "schemeId": ""\n }\n },\n "description": "",\n "itemPrice": "",\n "lineId": "",\n "lotNumberIds": [],\n "name": "",\n "note": "",\n "quantity": "",\n "quantityUnitCode": "",\n "references": [\n {}\n ],\n "taxesDutiesFees": [\n {}\n ]\n }\n ],\n "orderType": "",\n "paymentTerms": {},\n "references": [\n {}\n ],\n "sellerSupplierParty": {\n "party": {},\n "publicIdentifiers": [\n {}\n ]\n },\n "taxSystem": "",\n "timeZone": "",\n "validityPeriod": ""\n },\n "rawDocumentData": {\n "document": "",\n "documentTypeId": "",\n "parse": false,\n "parseStrategy": "",\n "processId": ""\n }\n },\n "idempotencyGuid": "",\n "legalEntityId": 0,\n "receiveGuid": "",\n "routing": {\n "clearWithoutSending": false,\n "eIdentifiers": [\n {\n "id": "",\n "scheme": ""\n }\n ],\n "emails": []\n }\n}'
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}")
val request = Request.Builder()
.url("{{baseUrl}}/document_submissions")
.post(body)
.addHeader("content-type", "application/json")
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'POST',
hostname: 'example.com',
port: null,
path: '/baseUrl/document_submissions',
headers: {
'content-type': 'application/json'
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({
attachments: [
{
description: '',
document: '',
documentId: '',
filename: '',
mimeType: '',
primaryImage: false
}
],
createPrimaryImage: false,
document: {
documentType: '',
invoice: {
accountingCost: '',
accountingCurrencyTaxAmount: '',
accountingCurrencyTaxAmountCurrency: '',
accountingCustomerParty: {
party: {
address: {city: '', country: '', county: '', street1: '', street2: '', zip: ''},
companyName: '',
contact: {email: '', firstName: '', id: '', lastName: '', phone: ''}
},
publicIdentifiers: [{id: '', scheme: ''}]
},
accountingSupplierParty: {party: {contact: {}}},
allowanceCharges: [
{
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
baseAmountExcludingTax: '',
baseAmountIncludingTax: '',
reason: '',
reasonCode: '',
tax: {amount: '', category: '', country: '', percentage: ''},
taxesDutiesFees: [{}]
}
],
amountIncludingVat: '',
attachments: [{}],
billingReference: '',
buyerReference: '',
consumerTaxMode: false,
contractDocumentReference: '',
delivery: {
actualDate: '',
deliveryLocation: {address: {}, id: '', locationName: '', schemeAgencyId: '', schemeId: ''},
deliveryParty: {party: {}},
deliveryPartyName: '',
quantity: '',
requestedDeliveryPeriod: '',
shippingMarks: ''
},
documentCurrencyCode: '',
dueDate: '',
invoiceLines: [
{
accountingCost: '',
additionalItemProperties: [{name: '', value: ''}],
allowanceCharge: '',
allowanceCharges: [
{amountExcludingTax: '', baseAmountExcludingTax: '', reason: '', reasonCode: ''}
],
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
buyersItemIdentification: '',
description: '',
invoicePeriod: '',
itemPrice: '',
lineId: '',
name: '',
note: '',
orderLineReferenceLineId: '',
quantity: '',
quantityUnitCode: '',
references: [{documentId: '', documentType: '', issueDate: '', lineId: ''}],
sellersItemIdentification: '',
standardItemIdentification: '',
standardItemIdentificationSchemeAgencyId: '',
standardItemIdentificationSchemeId: '',
tax: {},
taxesDutiesFees: [{}]
}
],
invoiceNumber: '',
invoicePeriod: '',
invoiceType: '',
issueDate: '',
issueReasons: [],
note: '',
orderReference: '',
paymentMeansArray: [
{
account: '',
amount: '',
branche_code: '',
code: '',
holder: '',
mandate: '',
network: '',
paymentId: ''
}
],
paymentMeansBic: '',
paymentMeansCode: '',
paymentMeansIban: '',
paymentMeansPaymentId: '',
paymentTerms: {note: ''},
preferredInvoiceType: '',
prepaidAmount: '',
priceMode: '',
projectReference: '',
references: [{}],
salesOrderId: '',
selfBillingMode: false,
taxExemptReason: '',
taxPointDate: '',
taxSubtotals: [{category: '', country: '', percentage: '', taxAmount: '', taxableAmount: ''}],
taxSystem: '',
taxesDutiesFees: [{}],
transactionType: '',
ublExtensions: [],
vatReverseCharge: false,
x2y: ''
},
invoiceResponse: {
clarifications: [
{
clarification: '',
clarificationCode: '',
clarificationCodeType: '',
conditions: [{fieldCode: '', fieldValue: ''}]
}
],
effectiveDate: '',
note: '',
responseCode: ''
},
order: {
accountingCost: '',
allowanceCharges: [{}],
amountIncludingTax: '',
attachments: [{}],
delivery: {},
deliveryTerms: {deliveryLocationId: '', incoterms: '', specialTerms: ''},
documentCurrencyCode: '',
documentNumber: '',
issueDate: '',
issueTime: '',
note: '',
orderLines: [
{
accountingCost: '',
additionalItemProperties: [{}],
allowPartialDelivery: false,
allowanceCharges: [{}],
amountExcludingTax: '',
baseQuantity: '',
delivery: {deliveryLocation: {id: '', schemeId: ''}},
description: '',
itemPrice: '',
lineId: '',
lotNumberIds: [],
name: '',
note: '',
quantity: '',
quantityUnitCode: '',
references: [{}],
taxesDutiesFees: [{}]
}
],
orderType: '',
paymentTerms: {},
references: [{}],
sellerSupplierParty: {party: {}, publicIdentifiers: [{}]},
taxSystem: '',
timeZone: '',
validityPeriod: ''
},
rawDocumentData: {
document: '',
documentTypeId: '',
parse: false,
parseStrategy: '',
processId: ''
}
},
idempotencyGuid: '',
legalEntityId: 0,
receiveGuid: '',
routing: {clearWithoutSending: false, eIdentifiers: [{id: '', scheme: ''}], emails: []}
}));
req.end();
const request = require('request');
const options = {
method: 'POST',
url: '{{baseUrl}}/document_submissions',
headers: {'content-type': 'application/json'},
body: {
attachments: [
{
description: '',
document: '',
documentId: '',
filename: '',
mimeType: '',
primaryImage: false
}
],
createPrimaryImage: false,
document: {
documentType: '',
invoice: {
accountingCost: '',
accountingCurrencyTaxAmount: '',
accountingCurrencyTaxAmountCurrency: '',
accountingCustomerParty: {
party: {
address: {city: '', country: '', county: '', street1: '', street2: '', zip: ''},
companyName: '',
contact: {email: '', firstName: '', id: '', lastName: '', phone: ''}
},
publicIdentifiers: [{id: '', scheme: ''}]
},
accountingSupplierParty: {party: {contact: {}}},
allowanceCharges: [
{
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
baseAmountExcludingTax: '',
baseAmountIncludingTax: '',
reason: '',
reasonCode: '',
tax: {amount: '', category: '', country: '', percentage: ''},
taxesDutiesFees: [{}]
}
],
amountIncludingVat: '',
attachments: [{}],
billingReference: '',
buyerReference: '',
consumerTaxMode: false,
contractDocumentReference: '',
delivery: {
actualDate: '',
deliveryLocation: {address: {}, id: '', locationName: '', schemeAgencyId: '', schemeId: ''},
deliveryParty: {party: {}},
deliveryPartyName: '',
quantity: '',
requestedDeliveryPeriod: '',
shippingMarks: ''
},
documentCurrencyCode: '',
dueDate: '',
invoiceLines: [
{
accountingCost: '',
additionalItemProperties: [{name: '', value: ''}],
allowanceCharge: '',
allowanceCharges: [
{amountExcludingTax: '', baseAmountExcludingTax: '', reason: '', reasonCode: ''}
],
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
buyersItemIdentification: '',
description: '',
invoicePeriod: '',
itemPrice: '',
lineId: '',
name: '',
note: '',
orderLineReferenceLineId: '',
quantity: '',
quantityUnitCode: '',
references: [{documentId: '', documentType: '', issueDate: '', lineId: ''}],
sellersItemIdentification: '',
standardItemIdentification: '',
standardItemIdentificationSchemeAgencyId: '',
standardItemIdentificationSchemeId: '',
tax: {},
taxesDutiesFees: [{}]
}
],
invoiceNumber: '',
invoicePeriod: '',
invoiceType: '',
issueDate: '',
issueReasons: [],
note: '',
orderReference: '',
paymentMeansArray: [
{
account: '',
amount: '',
branche_code: '',
code: '',
holder: '',
mandate: '',
network: '',
paymentId: ''
}
],
paymentMeansBic: '',
paymentMeansCode: '',
paymentMeansIban: '',
paymentMeansPaymentId: '',
paymentTerms: {note: ''},
preferredInvoiceType: '',
prepaidAmount: '',
priceMode: '',
projectReference: '',
references: [{}],
salesOrderId: '',
selfBillingMode: false,
taxExemptReason: '',
taxPointDate: '',
taxSubtotals: [{category: '', country: '', percentage: '', taxAmount: '', taxableAmount: ''}],
taxSystem: '',
taxesDutiesFees: [{}],
transactionType: '',
ublExtensions: [],
vatReverseCharge: false,
x2y: ''
},
invoiceResponse: {
clarifications: [
{
clarification: '',
clarificationCode: '',
clarificationCodeType: '',
conditions: [{fieldCode: '', fieldValue: ''}]
}
],
effectiveDate: '',
note: '',
responseCode: ''
},
order: {
accountingCost: '',
allowanceCharges: [{}],
amountIncludingTax: '',
attachments: [{}],
delivery: {},
deliveryTerms: {deliveryLocationId: '', incoterms: '', specialTerms: ''},
documentCurrencyCode: '',
documentNumber: '',
issueDate: '',
issueTime: '',
note: '',
orderLines: [
{
accountingCost: '',
additionalItemProperties: [{}],
allowPartialDelivery: false,
allowanceCharges: [{}],
amountExcludingTax: '',
baseQuantity: '',
delivery: {deliveryLocation: {id: '', schemeId: ''}},
description: '',
itemPrice: '',
lineId: '',
lotNumberIds: [],
name: '',
note: '',
quantity: '',
quantityUnitCode: '',
references: [{}],
taxesDutiesFees: [{}]
}
],
orderType: '',
paymentTerms: {},
references: [{}],
sellerSupplierParty: {party: {}, publicIdentifiers: [{}]},
taxSystem: '',
timeZone: '',
validityPeriod: ''
},
rawDocumentData: {
document: '',
documentTypeId: '',
parse: false,
parseStrategy: '',
processId: ''
}
},
idempotencyGuid: '',
legalEntityId: 0,
receiveGuid: '',
routing: {clearWithoutSending: false, eIdentifiers: [{id: '', scheme: ''}], emails: []}
},
json: true
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('POST', '{{baseUrl}}/document_submissions');
req.headers({
'content-type': 'application/json'
});
req.type('json');
req.send({
attachments: [
{
description: '',
document: '',
documentId: '',
filename: '',
mimeType: '',
primaryImage: false
}
],
createPrimaryImage: false,
document: {
documentType: '',
invoice: {
accountingCost: '',
accountingCurrencyTaxAmount: '',
accountingCurrencyTaxAmountCurrency: '',
accountingCustomerParty: {
party: {
address: {
city: '',
country: '',
county: '',
street1: '',
street2: '',
zip: ''
},
companyName: '',
contact: {
email: '',
firstName: '',
id: '',
lastName: '',
phone: ''
}
},
publicIdentifiers: [
{
id: '',
scheme: ''
}
]
},
accountingSupplierParty: {
party: {
contact: {}
}
},
allowanceCharges: [
{
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
baseAmountExcludingTax: '',
baseAmountIncludingTax: '',
reason: '',
reasonCode: '',
tax: {
amount: '',
category: '',
country: '',
percentage: ''
},
taxesDutiesFees: [
{}
]
}
],
amountIncludingVat: '',
attachments: [
{}
],
billingReference: '',
buyerReference: '',
consumerTaxMode: false,
contractDocumentReference: '',
delivery: {
actualDate: '',
deliveryLocation: {
address: {},
id: '',
locationName: '',
schemeAgencyId: '',
schemeId: ''
},
deliveryParty: {
party: {}
},
deliveryPartyName: '',
quantity: '',
requestedDeliveryPeriod: '',
shippingMarks: ''
},
documentCurrencyCode: '',
dueDate: '',
invoiceLines: [
{
accountingCost: '',
additionalItemProperties: [
{
name: '',
value: ''
}
],
allowanceCharge: '',
allowanceCharges: [
{
amountExcludingTax: '',
baseAmountExcludingTax: '',
reason: '',
reasonCode: ''
}
],
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
buyersItemIdentification: '',
description: '',
invoicePeriod: '',
itemPrice: '',
lineId: '',
name: '',
note: '',
orderLineReferenceLineId: '',
quantity: '',
quantityUnitCode: '',
references: [
{
documentId: '',
documentType: '',
issueDate: '',
lineId: ''
}
],
sellersItemIdentification: '',
standardItemIdentification: '',
standardItemIdentificationSchemeAgencyId: '',
standardItemIdentificationSchemeId: '',
tax: {},
taxesDutiesFees: [
{}
]
}
],
invoiceNumber: '',
invoicePeriod: '',
invoiceType: '',
issueDate: '',
issueReasons: [],
note: '',
orderReference: '',
paymentMeansArray: [
{
account: '',
amount: '',
branche_code: '',
code: '',
holder: '',
mandate: '',
network: '',
paymentId: ''
}
],
paymentMeansBic: '',
paymentMeansCode: '',
paymentMeansIban: '',
paymentMeansPaymentId: '',
paymentTerms: {
note: ''
},
preferredInvoiceType: '',
prepaidAmount: '',
priceMode: '',
projectReference: '',
references: [
{}
],
salesOrderId: '',
selfBillingMode: false,
taxExemptReason: '',
taxPointDate: '',
taxSubtotals: [
{
category: '',
country: '',
percentage: '',
taxAmount: '',
taxableAmount: ''
}
],
taxSystem: '',
taxesDutiesFees: [
{}
],
transactionType: '',
ublExtensions: [],
vatReverseCharge: false,
x2y: ''
},
invoiceResponse: {
clarifications: [
{
clarification: '',
clarificationCode: '',
clarificationCodeType: '',
conditions: [
{
fieldCode: '',
fieldValue: ''
}
]
}
],
effectiveDate: '',
note: '',
responseCode: ''
},
order: {
accountingCost: '',
allowanceCharges: [
{}
],
amountIncludingTax: '',
attachments: [
{}
],
delivery: {},
deliveryTerms: {
deliveryLocationId: '',
incoterms: '',
specialTerms: ''
},
documentCurrencyCode: '',
documentNumber: '',
issueDate: '',
issueTime: '',
note: '',
orderLines: [
{
accountingCost: '',
additionalItemProperties: [
{}
],
allowPartialDelivery: false,
allowanceCharges: [
{}
],
amountExcludingTax: '',
baseQuantity: '',
delivery: {
deliveryLocation: {
id: '',
schemeId: ''
}
},
description: '',
itemPrice: '',
lineId: '',
lotNumberIds: [],
name: '',
note: '',
quantity: '',
quantityUnitCode: '',
references: [
{}
],
taxesDutiesFees: [
{}
]
}
],
orderType: '',
paymentTerms: {},
references: [
{}
],
sellerSupplierParty: {
party: {},
publicIdentifiers: [
{}
]
},
taxSystem: '',
timeZone: '',
validityPeriod: ''
},
rawDocumentData: {
document: '',
documentTypeId: '',
parse: false,
parseStrategy: '',
processId: ''
}
},
idempotencyGuid: '',
legalEntityId: 0,
receiveGuid: '',
routing: {
clearWithoutSending: false,
eIdentifiers: [
{
id: '',
scheme: ''
}
],
emails: []
}
});
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'POST',
url: '{{baseUrl}}/document_submissions',
headers: {'content-type': 'application/json'},
data: {
attachments: [
{
description: '',
document: '',
documentId: '',
filename: '',
mimeType: '',
primaryImage: false
}
],
createPrimaryImage: false,
document: {
documentType: '',
invoice: {
accountingCost: '',
accountingCurrencyTaxAmount: '',
accountingCurrencyTaxAmountCurrency: '',
accountingCustomerParty: {
party: {
address: {city: '', country: '', county: '', street1: '', street2: '', zip: ''},
companyName: '',
contact: {email: '', firstName: '', id: '', lastName: '', phone: ''}
},
publicIdentifiers: [{id: '', scheme: ''}]
},
accountingSupplierParty: {party: {contact: {}}},
allowanceCharges: [
{
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
baseAmountExcludingTax: '',
baseAmountIncludingTax: '',
reason: '',
reasonCode: '',
tax: {amount: '', category: '', country: '', percentage: ''},
taxesDutiesFees: [{}]
}
],
amountIncludingVat: '',
attachments: [{}],
billingReference: '',
buyerReference: '',
consumerTaxMode: false,
contractDocumentReference: '',
delivery: {
actualDate: '',
deliveryLocation: {address: {}, id: '', locationName: '', schemeAgencyId: '', schemeId: ''},
deliveryParty: {party: {}},
deliveryPartyName: '',
quantity: '',
requestedDeliveryPeriod: '',
shippingMarks: ''
},
documentCurrencyCode: '',
dueDate: '',
invoiceLines: [
{
accountingCost: '',
additionalItemProperties: [{name: '', value: ''}],
allowanceCharge: '',
allowanceCharges: [
{amountExcludingTax: '', baseAmountExcludingTax: '', reason: '', reasonCode: ''}
],
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
buyersItemIdentification: '',
description: '',
invoicePeriod: '',
itemPrice: '',
lineId: '',
name: '',
note: '',
orderLineReferenceLineId: '',
quantity: '',
quantityUnitCode: '',
references: [{documentId: '', documentType: '', issueDate: '', lineId: ''}],
sellersItemIdentification: '',
standardItemIdentification: '',
standardItemIdentificationSchemeAgencyId: '',
standardItemIdentificationSchemeId: '',
tax: {},
taxesDutiesFees: [{}]
}
],
invoiceNumber: '',
invoicePeriod: '',
invoiceType: '',
issueDate: '',
issueReasons: [],
note: '',
orderReference: '',
paymentMeansArray: [
{
account: '',
amount: '',
branche_code: '',
code: '',
holder: '',
mandate: '',
network: '',
paymentId: ''
}
],
paymentMeansBic: '',
paymentMeansCode: '',
paymentMeansIban: '',
paymentMeansPaymentId: '',
paymentTerms: {note: ''},
preferredInvoiceType: '',
prepaidAmount: '',
priceMode: '',
projectReference: '',
references: [{}],
salesOrderId: '',
selfBillingMode: false,
taxExemptReason: '',
taxPointDate: '',
taxSubtotals: [{category: '', country: '', percentage: '', taxAmount: '', taxableAmount: ''}],
taxSystem: '',
taxesDutiesFees: [{}],
transactionType: '',
ublExtensions: [],
vatReverseCharge: false,
x2y: ''
},
invoiceResponse: {
clarifications: [
{
clarification: '',
clarificationCode: '',
clarificationCodeType: '',
conditions: [{fieldCode: '', fieldValue: ''}]
}
],
effectiveDate: '',
note: '',
responseCode: ''
},
order: {
accountingCost: '',
allowanceCharges: [{}],
amountIncludingTax: '',
attachments: [{}],
delivery: {},
deliveryTerms: {deliveryLocationId: '', incoterms: '', specialTerms: ''},
documentCurrencyCode: '',
documentNumber: '',
issueDate: '',
issueTime: '',
note: '',
orderLines: [
{
accountingCost: '',
additionalItemProperties: [{}],
allowPartialDelivery: false,
allowanceCharges: [{}],
amountExcludingTax: '',
baseQuantity: '',
delivery: {deliveryLocation: {id: '', schemeId: ''}},
description: '',
itemPrice: '',
lineId: '',
lotNumberIds: [],
name: '',
note: '',
quantity: '',
quantityUnitCode: '',
references: [{}],
taxesDutiesFees: [{}]
}
],
orderType: '',
paymentTerms: {},
references: [{}],
sellerSupplierParty: {party: {}, publicIdentifiers: [{}]},
taxSystem: '',
timeZone: '',
validityPeriod: ''
},
rawDocumentData: {
document: '',
documentTypeId: '',
parse: false,
parseStrategy: '',
processId: ''
}
},
idempotencyGuid: '',
legalEntityId: 0,
receiveGuid: '',
routing: {clearWithoutSending: false, eIdentifiers: [{id: '', scheme: ''}], emails: []}
}
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/document_submissions';
const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: '{"attachments":[{"description":"","document":"","documentId":"","filename":"","mimeType":"","primaryImage":false}],"createPrimaryImage":false,"document":{"documentType":"","invoice":{"accountingCost":"","accountingCurrencyTaxAmount":"","accountingCurrencyTaxAmountCurrency":"","accountingCustomerParty":{"party":{"address":{"city":"","country":"","county":"","street1":"","street2":"","zip":""},"companyName":"","contact":{"email":"","firstName":"","id":"","lastName":"","phone":""}},"publicIdentifiers":[{"id":"","scheme":""}]},"accountingSupplierParty":{"party":{"contact":{}}},"allowanceCharges":[{"amountExcludingTax":"","amountExcludingVat":"","amountIncludingTax":"","baseAmountExcludingTax":"","baseAmountIncludingTax":"","reason":"","reasonCode":"","tax":{"amount":"","category":"","country":"","percentage":""},"taxesDutiesFees":[{}]}],"amountIncludingVat":"","attachments":[{}],"billingReference":"","buyerReference":"","consumerTaxMode":false,"contractDocumentReference":"","delivery":{"actualDate":"","deliveryLocation":{"address":{},"id":"","locationName":"","schemeAgencyId":"","schemeId":""},"deliveryParty":{"party":{}},"deliveryPartyName":"","quantity":"","requestedDeliveryPeriod":"","shippingMarks":""},"documentCurrencyCode":"","dueDate":"","invoiceLines":[{"accountingCost":"","additionalItemProperties":[{"name":"","value":""}],"allowanceCharge":"","allowanceCharges":[{"amountExcludingTax":"","baseAmountExcludingTax":"","reason":"","reasonCode":""}],"amountExcludingTax":"","amountExcludingVat":"","amountIncludingTax":"","buyersItemIdentification":"","description":"","invoicePeriod":"","itemPrice":"","lineId":"","name":"","note":"","orderLineReferenceLineId":"","quantity":"","quantityUnitCode":"","references":[{"documentId":"","documentType":"","issueDate":"","lineId":""}],"sellersItemIdentification":"","standardItemIdentification":"","standardItemIdentificationSchemeAgencyId":"","standardItemIdentificationSchemeId":"","tax":{},"taxesDutiesFees":[{}]}],"invoiceNumber":"","invoicePeriod":"","invoiceType":"","issueDate":"","issueReasons":[],"note":"","orderReference":"","paymentMeansArray":[{"account":"","amount":"","branche_code":"","code":"","holder":"","mandate":"","network":"","paymentId":""}],"paymentMeansBic":"","paymentMeansCode":"","paymentMeansIban":"","paymentMeansPaymentId":"","paymentTerms":{"note":""},"preferredInvoiceType":"","prepaidAmount":"","priceMode":"","projectReference":"","references":[{}],"salesOrderId":"","selfBillingMode":false,"taxExemptReason":"","taxPointDate":"","taxSubtotals":[{"category":"","country":"","percentage":"","taxAmount":"","taxableAmount":""}],"taxSystem":"","taxesDutiesFees":[{}],"transactionType":"","ublExtensions":[],"vatReverseCharge":false,"x2y":""},"invoiceResponse":{"clarifications":[{"clarification":"","clarificationCode":"","clarificationCodeType":"","conditions":[{"fieldCode":"","fieldValue":""}]}],"effectiveDate":"","note":"","responseCode":""},"order":{"accountingCost":"","allowanceCharges":[{}],"amountIncludingTax":"","attachments":[{}],"delivery":{},"deliveryTerms":{"deliveryLocationId":"","incoterms":"","specialTerms":""},"documentCurrencyCode":"","documentNumber":"","issueDate":"","issueTime":"","note":"","orderLines":[{"accountingCost":"","additionalItemProperties":[{}],"allowPartialDelivery":false,"allowanceCharges":[{}],"amountExcludingTax":"","baseQuantity":"","delivery":{"deliveryLocation":{"id":"","schemeId":""}},"description":"","itemPrice":"","lineId":"","lotNumberIds":[],"name":"","note":"","quantity":"","quantityUnitCode":"","references":[{}],"taxesDutiesFees":[{}]}],"orderType":"","paymentTerms":{},"references":[{}],"sellerSupplierParty":{"party":{},"publicIdentifiers":[{}]},"taxSystem":"","timeZone":"","validityPeriod":""},"rawDocumentData":{"document":"","documentTypeId":"","parse":false,"parseStrategy":"","processId":""}},"idempotencyGuid":"","legalEntityId":0,"receiveGuid":"","routing":{"clearWithoutSending":false,"eIdentifiers":[{"id":"","scheme":""}],"emails":[]}}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"attachments": @[ @{ @"description": @"", @"document": @"", @"documentId": @"", @"filename": @"", @"mimeType": @"", @"primaryImage": @NO } ],
@"createPrimaryImage": @NO,
@"document": @{ @"documentType": @"", @"invoice": @{ @"accountingCost": @"", @"accountingCurrencyTaxAmount": @"", @"accountingCurrencyTaxAmountCurrency": @"", @"accountingCustomerParty": @{ @"party": @{ @"address": @{ @"city": @"", @"country": @"", @"county": @"", @"street1": @"", @"street2": @"", @"zip": @"" }, @"companyName": @"", @"contact": @{ @"email": @"", @"firstName": @"", @"id": @"", @"lastName": @"", @"phone": @"" } }, @"publicIdentifiers": @[ @{ @"id": @"", @"scheme": @"" } ] }, @"accountingSupplierParty": @{ @"party": @{ @"contact": @{ } } }, @"allowanceCharges": @[ @{ @"amountExcludingTax": @"", @"amountExcludingVat": @"", @"amountIncludingTax": @"", @"baseAmountExcludingTax": @"", @"baseAmountIncludingTax": @"", @"reason": @"", @"reasonCode": @"", @"tax": @{ @"amount": @"", @"category": @"", @"country": @"", @"percentage": @"" }, @"taxesDutiesFees": @[ @{ } ] } ], @"amountIncludingVat": @"", @"attachments": @[ @{ } ], @"billingReference": @"", @"buyerReference": @"", @"consumerTaxMode": @NO, @"contractDocumentReference": @"", @"delivery": @{ @"actualDate": @"", @"deliveryLocation": @{ @"address": @{ }, @"id": @"", @"locationName": @"", @"schemeAgencyId": @"", @"schemeId": @"" }, @"deliveryParty": @{ @"party": @{ } }, @"deliveryPartyName": @"", @"quantity": @"", @"requestedDeliveryPeriod": @"", @"shippingMarks": @"" }, @"documentCurrencyCode": @"", @"dueDate": @"", @"invoiceLines": @[ @{ @"accountingCost": @"", @"additionalItemProperties": @[ @{ @"name": @"", @"value": @"" } ], @"allowanceCharge": @"", @"allowanceCharges": @[ @{ @"amountExcludingTax": @"", @"baseAmountExcludingTax": @"", @"reason": @"", @"reasonCode": @"" } ], @"amountExcludingTax": @"", @"amountExcludingVat": @"", @"amountIncludingTax": @"", @"buyersItemIdentification": @"", @"description": @"", @"invoicePeriod": @"", @"itemPrice": @"", @"lineId": @"", @"name": @"", @"note": @"", @"orderLineReferenceLineId": @"", @"quantity": @"", @"quantityUnitCode": @"", @"references": @[ @{ @"documentId": @"", @"documentType": @"", @"issueDate": @"", @"lineId": @"" } ], @"sellersItemIdentification": @"", @"standardItemIdentification": @"", @"standardItemIdentificationSchemeAgencyId": @"", @"standardItemIdentificationSchemeId": @"", @"tax": @{ }, @"taxesDutiesFees": @[ @{ } ] } ], @"invoiceNumber": @"", @"invoicePeriod": @"", @"invoiceType": @"", @"issueDate": @"", @"issueReasons": @[ ], @"note": @"", @"orderReference": @"", @"paymentMeansArray": @[ @{ @"account": @"", @"amount": @"", @"branche_code": @"", @"code": @"", @"holder": @"", @"mandate": @"", @"network": @"", @"paymentId": @"" } ], @"paymentMeansBic": @"", @"paymentMeansCode": @"", @"paymentMeansIban": @"", @"paymentMeansPaymentId": @"", @"paymentTerms": @{ @"note": @"" }, @"preferredInvoiceType": @"", @"prepaidAmount": @"", @"priceMode": @"", @"projectReference": @"", @"references": @[ @{ } ], @"salesOrderId": @"", @"selfBillingMode": @NO, @"taxExemptReason": @"", @"taxPointDate": @"", @"taxSubtotals": @[ @{ @"category": @"", @"country": @"", @"percentage": @"", @"taxAmount": @"", @"taxableAmount": @"" } ], @"taxSystem": @"", @"taxesDutiesFees": @[ @{ } ], @"transactionType": @"", @"ublExtensions": @[ ], @"vatReverseCharge": @NO, @"x2y": @"" }, @"invoiceResponse": @{ @"clarifications": @[ @{ @"clarification": @"", @"clarificationCode": @"", @"clarificationCodeType": @"", @"conditions": @[ @{ @"fieldCode": @"", @"fieldValue": @"" } ] } ], @"effectiveDate": @"", @"note": @"", @"responseCode": @"" }, @"order": @{ @"accountingCost": @"", @"allowanceCharges": @[ @{ } ], @"amountIncludingTax": @"", @"attachments": @[ @{ } ], @"delivery": @{ }, @"deliveryTerms": @{ @"deliveryLocationId": @"", @"incoterms": @"", @"specialTerms": @"" }, @"documentCurrencyCode": @"", @"documentNumber": @"", @"issueDate": @"", @"issueTime": @"", @"note": @"", @"orderLines": @[ @{ @"accountingCost": @"", @"additionalItemProperties": @[ @{ } ], @"allowPartialDelivery": @NO, @"allowanceCharges": @[ @{ } ], @"amountExcludingTax": @"", @"baseQuantity": @"", @"delivery": @{ @"deliveryLocation": @{ @"id": @"", @"schemeId": @"" } }, @"description": @"", @"itemPrice": @"", @"lineId": @"", @"lotNumberIds": @[ ], @"name": @"", @"note": @"", @"quantity": @"", @"quantityUnitCode": @"", @"references": @[ @{ } ], @"taxesDutiesFees": @[ @{ } ] } ], @"orderType": @"", @"paymentTerms": @{ }, @"references": @[ @{ } ], @"sellerSupplierParty": @{ @"party": @{ }, @"publicIdentifiers": @[ @{ } ] }, @"taxSystem": @"", @"timeZone": @"", @"validityPeriod": @"" }, @"rawDocumentData": @{ @"document": @"", @"documentTypeId": @"", @"parse": @NO, @"parseStrategy": @"", @"processId": @"" } },
@"idempotencyGuid": @"",
@"legalEntityId": @0,
@"receiveGuid": @"",
@"routing": @{ @"clearWithoutSending": @NO, @"eIdentifiers": @[ @{ @"id": @"", @"scheme": @"" } ], @"emails": @[ ] } };
NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/document_submissions"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/document_submissions" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}" in
Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/document_submissions",
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([
'attachments' => [
[
'description' => '',
'document' => '',
'documentId' => '',
'filename' => '',
'mimeType' => '',
'primaryImage' => null
]
],
'createPrimaryImage' => null,
'document' => [
'documentType' => '',
'invoice' => [
'accountingCost' => '',
'accountingCurrencyTaxAmount' => '',
'accountingCurrencyTaxAmountCurrency' => '',
'accountingCustomerParty' => [
'party' => [
'address' => [
'city' => '',
'country' => '',
'county' => '',
'street1' => '',
'street2' => '',
'zip' => ''
],
'companyName' => '',
'contact' => [
'email' => '',
'firstName' => '',
'id' => '',
'lastName' => '',
'phone' => ''
]
],
'publicIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
]
],
'accountingSupplierParty' => [
'party' => [
'contact' => [
]
]
],
'allowanceCharges' => [
[
'amountExcludingTax' => '',
'amountExcludingVat' => '',
'amountIncludingTax' => '',
'baseAmountExcludingTax' => '',
'baseAmountIncludingTax' => '',
'reason' => '',
'reasonCode' => '',
'tax' => [
'amount' => '',
'category' => '',
'country' => '',
'percentage' => ''
],
'taxesDutiesFees' => [
[
]
]
]
],
'amountIncludingVat' => '',
'attachments' => [
[
]
],
'billingReference' => '',
'buyerReference' => '',
'consumerTaxMode' => null,
'contractDocumentReference' => '',
'delivery' => [
'actualDate' => '',
'deliveryLocation' => [
'address' => [
],
'id' => '',
'locationName' => '',
'schemeAgencyId' => '',
'schemeId' => ''
],
'deliveryParty' => [
'party' => [
]
],
'deliveryPartyName' => '',
'quantity' => '',
'requestedDeliveryPeriod' => '',
'shippingMarks' => ''
],
'documentCurrencyCode' => '',
'dueDate' => '',
'invoiceLines' => [
[
'accountingCost' => '',
'additionalItemProperties' => [
[
'name' => '',
'value' => ''
]
],
'allowanceCharge' => '',
'allowanceCharges' => [
[
'amountExcludingTax' => '',
'baseAmountExcludingTax' => '',
'reason' => '',
'reasonCode' => ''
]
],
'amountExcludingTax' => '',
'amountExcludingVat' => '',
'amountIncludingTax' => '',
'buyersItemIdentification' => '',
'description' => '',
'invoicePeriod' => '',
'itemPrice' => '',
'lineId' => '',
'name' => '',
'note' => '',
'orderLineReferenceLineId' => '',
'quantity' => '',
'quantityUnitCode' => '',
'references' => [
[
'documentId' => '',
'documentType' => '',
'issueDate' => '',
'lineId' => ''
]
],
'sellersItemIdentification' => '',
'standardItemIdentification' => '',
'standardItemIdentificationSchemeAgencyId' => '',
'standardItemIdentificationSchemeId' => '',
'tax' => [
],
'taxesDutiesFees' => [
[
]
]
]
],
'invoiceNumber' => '',
'invoicePeriod' => '',
'invoiceType' => '',
'issueDate' => '',
'issueReasons' => [
],
'note' => '',
'orderReference' => '',
'paymentMeansArray' => [
[
'account' => '',
'amount' => '',
'branche_code' => '',
'code' => '',
'holder' => '',
'mandate' => '',
'network' => '',
'paymentId' => ''
]
],
'paymentMeansBic' => '',
'paymentMeansCode' => '',
'paymentMeansIban' => '',
'paymentMeansPaymentId' => '',
'paymentTerms' => [
'note' => ''
],
'preferredInvoiceType' => '',
'prepaidAmount' => '',
'priceMode' => '',
'projectReference' => '',
'references' => [
[
]
],
'salesOrderId' => '',
'selfBillingMode' => null,
'taxExemptReason' => '',
'taxPointDate' => '',
'taxSubtotals' => [
[
'category' => '',
'country' => '',
'percentage' => '',
'taxAmount' => '',
'taxableAmount' => ''
]
],
'taxSystem' => '',
'taxesDutiesFees' => [
[
]
],
'transactionType' => '',
'ublExtensions' => [
],
'vatReverseCharge' => null,
'x2y' => ''
],
'invoiceResponse' => [
'clarifications' => [
[
'clarification' => '',
'clarificationCode' => '',
'clarificationCodeType' => '',
'conditions' => [
[
'fieldCode' => '',
'fieldValue' => ''
]
]
]
],
'effectiveDate' => '',
'note' => '',
'responseCode' => ''
],
'order' => [
'accountingCost' => '',
'allowanceCharges' => [
[
]
],
'amountIncludingTax' => '',
'attachments' => [
[
]
],
'delivery' => [
],
'deliveryTerms' => [
'deliveryLocationId' => '',
'incoterms' => '',
'specialTerms' => ''
],
'documentCurrencyCode' => '',
'documentNumber' => '',
'issueDate' => '',
'issueTime' => '',
'note' => '',
'orderLines' => [
[
'accountingCost' => '',
'additionalItemProperties' => [
[
]
],
'allowPartialDelivery' => null,
'allowanceCharges' => [
[
]
],
'amountExcludingTax' => '',
'baseQuantity' => '',
'delivery' => [
'deliveryLocation' => [
'id' => '',
'schemeId' => ''
]
],
'description' => '',
'itemPrice' => '',
'lineId' => '',
'lotNumberIds' => [
],
'name' => '',
'note' => '',
'quantity' => '',
'quantityUnitCode' => '',
'references' => [
[
]
],
'taxesDutiesFees' => [
[
]
]
]
],
'orderType' => '',
'paymentTerms' => [
],
'references' => [
[
]
],
'sellerSupplierParty' => [
'party' => [
],
'publicIdentifiers' => [
[
]
]
],
'taxSystem' => '',
'timeZone' => '',
'validityPeriod' => ''
],
'rawDocumentData' => [
'document' => '',
'documentTypeId' => '',
'parse' => null,
'parseStrategy' => '',
'processId' => ''
]
],
'idempotencyGuid' => '',
'legalEntityId' => 0,
'receiveGuid' => '',
'routing' => [
'clearWithoutSending' => null,
'eIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
],
'emails' => [
]
]
]),
CURLOPT_HTTPHEADER => [
"content-type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('POST', '{{baseUrl}}/document_submissions', [
'body' => '{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": {
"documentType": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceResponse": {
"clarifications": [
{
"clarification": "",
"clarificationCode": "",
"clarificationCodeType": "",
"conditions": [
{
"fieldCode": "",
"fieldValue": ""
}
]
}
],
"effectiveDate": "",
"note": "",
"responseCode": ""
},
"order": {
"accountingCost": "",
"allowanceCharges": [
{}
],
"amountIncludingTax": "",
"attachments": [
{}
],
"delivery": {},
"deliveryTerms": {
"deliveryLocationId": "",
"incoterms": "",
"specialTerms": ""
},
"documentCurrencyCode": "",
"documentNumber": "",
"issueDate": "",
"issueTime": "",
"note": "",
"orderLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{}
],
"allowPartialDelivery": false,
"allowanceCharges": [
{}
],
"amountExcludingTax": "",
"baseQuantity": "",
"delivery": {
"deliveryLocation": {
"id": "",
"schemeId": ""
}
},
"description": "",
"itemPrice": "",
"lineId": "",
"lotNumberIds": [],
"name": "",
"note": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{}
],
"taxesDutiesFees": [
{}
]
}
],
"orderType": "",
"paymentTerms": {},
"references": [
{}
],
"sellerSupplierParty": {
"party": {},
"publicIdentifiers": [
{}
]
},
"taxSystem": "",
"timeZone": "",
"validityPeriod": ""
},
"rawDocumentData": {
"document": "",
"documentTypeId": "",
"parse": false,
"parseStrategy": "",
"processId": ""
}
},
"idempotencyGuid": "",
"legalEntityId": 0,
"receiveGuid": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
}
}',
'headers' => [
'content-type' => 'application/json',
],
]);
echo $response->getBody();
setUrl('{{baseUrl}}/document_submissions');
$request->setMethod(HTTP_METH_POST);
$request->setHeaders([
'content-type' => 'application/json'
]);
$request->setContentType('application/json');
$request->setBody(json_encode([
'attachments' => [
[
'description' => '',
'document' => '',
'documentId' => '',
'filename' => '',
'mimeType' => '',
'primaryImage' => null
]
],
'createPrimaryImage' => null,
'document' => [
'documentType' => '',
'invoice' => [
'accountingCost' => '',
'accountingCurrencyTaxAmount' => '',
'accountingCurrencyTaxAmountCurrency' => '',
'accountingCustomerParty' => [
'party' => [
'address' => [
'city' => '',
'country' => '',
'county' => '',
'street1' => '',
'street2' => '',
'zip' => ''
],
'companyName' => '',
'contact' => [
'email' => '',
'firstName' => '',
'id' => '',
'lastName' => '',
'phone' => ''
]
],
'publicIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
]
],
'accountingSupplierParty' => [
'party' => [
'contact' => [
]
]
],
'allowanceCharges' => [
[
'amountExcludingTax' => '',
'amountExcludingVat' => '',
'amountIncludingTax' => '',
'baseAmountExcludingTax' => '',
'baseAmountIncludingTax' => '',
'reason' => '',
'reasonCode' => '',
'tax' => [
'amount' => '',
'category' => '',
'country' => '',
'percentage' => ''
],
'taxesDutiesFees' => [
[
]
]
]
],
'amountIncludingVat' => '',
'attachments' => [
[
]
],
'billingReference' => '',
'buyerReference' => '',
'consumerTaxMode' => null,
'contractDocumentReference' => '',
'delivery' => [
'actualDate' => '',
'deliveryLocation' => [
'address' => [
],
'id' => '',
'locationName' => '',
'schemeAgencyId' => '',
'schemeId' => ''
],
'deliveryParty' => [
'party' => [
]
],
'deliveryPartyName' => '',
'quantity' => '',
'requestedDeliveryPeriod' => '',
'shippingMarks' => ''
],
'documentCurrencyCode' => '',
'dueDate' => '',
'invoiceLines' => [
[
'accountingCost' => '',
'additionalItemProperties' => [
[
'name' => '',
'value' => ''
]
],
'allowanceCharge' => '',
'allowanceCharges' => [
[
'amountExcludingTax' => '',
'baseAmountExcludingTax' => '',
'reason' => '',
'reasonCode' => ''
]
],
'amountExcludingTax' => '',
'amountExcludingVat' => '',
'amountIncludingTax' => '',
'buyersItemIdentification' => '',
'description' => '',
'invoicePeriod' => '',
'itemPrice' => '',
'lineId' => '',
'name' => '',
'note' => '',
'orderLineReferenceLineId' => '',
'quantity' => '',
'quantityUnitCode' => '',
'references' => [
[
'documentId' => '',
'documentType' => '',
'issueDate' => '',
'lineId' => ''
]
],
'sellersItemIdentification' => '',
'standardItemIdentification' => '',
'standardItemIdentificationSchemeAgencyId' => '',
'standardItemIdentificationSchemeId' => '',
'tax' => [
],
'taxesDutiesFees' => [
[
]
]
]
],
'invoiceNumber' => '',
'invoicePeriod' => '',
'invoiceType' => '',
'issueDate' => '',
'issueReasons' => [
],
'note' => '',
'orderReference' => '',
'paymentMeansArray' => [
[
'account' => '',
'amount' => '',
'branche_code' => '',
'code' => '',
'holder' => '',
'mandate' => '',
'network' => '',
'paymentId' => ''
]
],
'paymentMeansBic' => '',
'paymentMeansCode' => '',
'paymentMeansIban' => '',
'paymentMeansPaymentId' => '',
'paymentTerms' => [
'note' => ''
],
'preferredInvoiceType' => '',
'prepaidAmount' => '',
'priceMode' => '',
'projectReference' => '',
'references' => [
[
]
],
'salesOrderId' => '',
'selfBillingMode' => null,
'taxExemptReason' => '',
'taxPointDate' => '',
'taxSubtotals' => [
[
'category' => '',
'country' => '',
'percentage' => '',
'taxAmount' => '',
'taxableAmount' => ''
]
],
'taxSystem' => '',
'taxesDutiesFees' => [
[
]
],
'transactionType' => '',
'ublExtensions' => [
],
'vatReverseCharge' => null,
'x2y' => ''
],
'invoiceResponse' => [
'clarifications' => [
[
'clarification' => '',
'clarificationCode' => '',
'clarificationCodeType' => '',
'conditions' => [
[
'fieldCode' => '',
'fieldValue' => ''
]
]
]
],
'effectiveDate' => '',
'note' => '',
'responseCode' => ''
],
'order' => [
'accountingCost' => '',
'allowanceCharges' => [
[
]
],
'amountIncludingTax' => '',
'attachments' => [
[
]
],
'delivery' => [
],
'deliveryTerms' => [
'deliveryLocationId' => '',
'incoterms' => '',
'specialTerms' => ''
],
'documentCurrencyCode' => '',
'documentNumber' => '',
'issueDate' => '',
'issueTime' => '',
'note' => '',
'orderLines' => [
[
'accountingCost' => '',
'additionalItemProperties' => [
[
]
],
'allowPartialDelivery' => null,
'allowanceCharges' => [
[
]
],
'amountExcludingTax' => '',
'baseQuantity' => '',
'delivery' => [
'deliveryLocation' => [
'id' => '',
'schemeId' => ''
]
],
'description' => '',
'itemPrice' => '',
'lineId' => '',
'lotNumberIds' => [
],
'name' => '',
'note' => '',
'quantity' => '',
'quantityUnitCode' => '',
'references' => [
[
]
],
'taxesDutiesFees' => [
[
]
]
]
],
'orderType' => '',
'paymentTerms' => [
],
'references' => [
[
]
],
'sellerSupplierParty' => [
'party' => [
],
'publicIdentifiers' => [
[
]
]
],
'taxSystem' => '',
'timeZone' => '',
'validityPeriod' => ''
],
'rawDocumentData' => [
'document' => '',
'documentTypeId' => '',
'parse' => null,
'parseStrategy' => '',
'processId' => ''
]
],
'idempotencyGuid' => '',
'legalEntityId' => 0,
'receiveGuid' => '',
'routing' => [
'clearWithoutSending' => null,
'eIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
],
'emails' => [
]
]
]));
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
append(json_encode([
'attachments' => [
[
'description' => '',
'document' => '',
'documentId' => '',
'filename' => '',
'mimeType' => '',
'primaryImage' => null
]
],
'createPrimaryImage' => null,
'document' => [
'documentType' => '',
'invoice' => [
'accountingCost' => '',
'accountingCurrencyTaxAmount' => '',
'accountingCurrencyTaxAmountCurrency' => '',
'accountingCustomerParty' => [
'party' => [
'address' => [
'city' => '',
'country' => '',
'county' => '',
'street1' => '',
'street2' => '',
'zip' => ''
],
'companyName' => '',
'contact' => [
'email' => '',
'firstName' => '',
'id' => '',
'lastName' => '',
'phone' => ''
]
],
'publicIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
]
],
'accountingSupplierParty' => [
'party' => [
'contact' => [
]
]
],
'allowanceCharges' => [
[
'amountExcludingTax' => '',
'amountExcludingVat' => '',
'amountIncludingTax' => '',
'baseAmountExcludingTax' => '',
'baseAmountIncludingTax' => '',
'reason' => '',
'reasonCode' => '',
'tax' => [
'amount' => '',
'category' => '',
'country' => '',
'percentage' => ''
],
'taxesDutiesFees' => [
[
]
]
]
],
'amountIncludingVat' => '',
'attachments' => [
[
]
],
'billingReference' => '',
'buyerReference' => '',
'consumerTaxMode' => null,
'contractDocumentReference' => '',
'delivery' => [
'actualDate' => '',
'deliveryLocation' => [
'address' => [
],
'id' => '',
'locationName' => '',
'schemeAgencyId' => '',
'schemeId' => ''
],
'deliveryParty' => [
'party' => [
]
],
'deliveryPartyName' => '',
'quantity' => '',
'requestedDeliveryPeriod' => '',
'shippingMarks' => ''
],
'documentCurrencyCode' => '',
'dueDate' => '',
'invoiceLines' => [
[
'accountingCost' => '',
'additionalItemProperties' => [
[
'name' => '',
'value' => ''
]
],
'allowanceCharge' => '',
'allowanceCharges' => [
[
'amountExcludingTax' => '',
'baseAmountExcludingTax' => '',
'reason' => '',
'reasonCode' => ''
]
],
'amountExcludingTax' => '',
'amountExcludingVat' => '',
'amountIncludingTax' => '',
'buyersItemIdentification' => '',
'description' => '',
'invoicePeriod' => '',
'itemPrice' => '',
'lineId' => '',
'name' => '',
'note' => '',
'orderLineReferenceLineId' => '',
'quantity' => '',
'quantityUnitCode' => '',
'references' => [
[
'documentId' => '',
'documentType' => '',
'issueDate' => '',
'lineId' => ''
]
],
'sellersItemIdentification' => '',
'standardItemIdentification' => '',
'standardItemIdentificationSchemeAgencyId' => '',
'standardItemIdentificationSchemeId' => '',
'tax' => [
],
'taxesDutiesFees' => [
[
]
]
]
],
'invoiceNumber' => '',
'invoicePeriod' => '',
'invoiceType' => '',
'issueDate' => '',
'issueReasons' => [
],
'note' => '',
'orderReference' => '',
'paymentMeansArray' => [
[
'account' => '',
'amount' => '',
'branche_code' => '',
'code' => '',
'holder' => '',
'mandate' => '',
'network' => '',
'paymentId' => ''
]
],
'paymentMeansBic' => '',
'paymentMeansCode' => '',
'paymentMeansIban' => '',
'paymentMeansPaymentId' => '',
'paymentTerms' => [
'note' => ''
],
'preferredInvoiceType' => '',
'prepaidAmount' => '',
'priceMode' => '',
'projectReference' => '',
'references' => [
[
]
],
'salesOrderId' => '',
'selfBillingMode' => null,
'taxExemptReason' => '',
'taxPointDate' => '',
'taxSubtotals' => [
[
'category' => '',
'country' => '',
'percentage' => '',
'taxAmount' => '',
'taxableAmount' => ''
]
],
'taxSystem' => '',
'taxesDutiesFees' => [
[
]
],
'transactionType' => '',
'ublExtensions' => [
],
'vatReverseCharge' => null,
'x2y' => ''
],
'invoiceResponse' => [
'clarifications' => [
[
'clarification' => '',
'clarificationCode' => '',
'clarificationCodeType' => '',
'conditions' => [
[
'fieldCode' => '',
'fieldValue' => ''
]
]
]
],
'effectiveDate' => '',
'note' => '',
'responseCode' => ''
],
'order' => [
'accountingCost' => '',
'allowanceCharges' => [
[
]
],
'amountIncludingTax' => '',
'attachments' => [
[
]
],
'delivery' => [
],
'deliveryTerms' => [
'deliveryLocationId' => '',
'incoterms' => '',
'specialTerms' => ''
],
'documentCurrencyCode' => '',
'documentNumber' => '',
'issueDate' => '',
'issueTime' => '',
'note' => '',
'orderLines' => [
[
'accountingCost' => '',
'additionalItemProperties' => [
[
]
],
'allowPartialDelivery' => null,
'allowanceCharges' => [
[
]
],
'amountExcludingTax' => '',
'baseQuantity' => '',
'delivery' => [
'deliveryLocation' => [
'id' => '',
'schemeId' => ''
]
],
'description' => '',
'itemPrice' => '',
'lineId' => '',
'lotNumberIds' => [
],
'name' => '',
'note' => '',
'quantity' => '',
'quantityUnitCode' => '',
'references' => [
[
]
],
'taxesDutiesFees' => [
[
]
]
]
],
'orderType' => '',
'paymentTerms' => [
],
'references' => [
[
]
],
'sellerSupplierParty' => [
'party' => [
],
'publicIdentifiers' => [
[
]
]
],
'taxSystem' => '',
'timeZone' => '',
'validityPeriod' => ''
],
'rawDocumentData' => [
'document' => '',
'documentTypeId' => '',
'parse' => null,
'parseStrategy' => '',
'processId' => ''
]
],
'idempotencyGuid' => '',
'legalEntityId' => 0,
'receiveGuid' => '',
'routing' => [
'clearWithoutSending' => null,
'eIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
],
'emails' => [
]
]
]));
$request->setRequestUrl('{{baseUrl}}/document_submissions');
$request->setRequestMethod('POST');
$request->setBody($body);
$request->setHeaders([
'content-type' => 'application/json'
]);
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/document_submissions' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": {
"documentType": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceResponse": {
"clarifications": [
{
"clarification": "",
"clarificationCode": "",
"clarificationCodeType": "",
"conditions": [
{
"fieldCode": "",
"fieldValue": ""
}
]
}
],
"effectiveDate": "",
"note": "",
"responseCode": ""
},
"order": {
"accountingCost": "",
"allowanceCharges": [
{}
],
"amountIncludingTax": "",
"attachments": [
{}
],
"delivery": {},
"deliveryTerms": {
"deliveryLocationId": "",
"incoterms": "",
"specialTerms": ""
},
"documentCurrencyCode": "",
"documentNumber": "",
"issueDate": "",
"issueTime": "",
"note": "",
"orderLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{}
],
"allowPartialDelivery": false,
"allowanceCharges": [
{}
],
"amountExcludingTax": "",
"baseQuantity": "",
"delivery": {
"deliveryLocation": {
"id": "",
"schemeId": ""
}
},
"description": "",
"itemPrice": "",
"lineId": "",
"lotNumberIds": [],
"name": "",
"note": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{}
],
"taxesDutiesFees": [
{}
]
}
],
"orderType": "",
"paymentTerms": {},
"references": [
{}
],
"sellerSupplierParty": {
"party": {},
"publicIdentifiers": [
{}
]
},
"taxSystem": "",
"timeZone": "",
"validityPeriod": ""
},
"rawDocumentData": {
"document": "",
"documentTypeId": "",
"parse": false,
"parseStrategy": "",
"processId": ""
}
},
"idempotencyGuid": "",
"legalEntityId": 0,
"receiveGuid": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
}
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/document_submissions' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": {
"documentType": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceResponse": {
"clarifications": [
{
"clarification": "",
"clarificationCode": "",
"clarificationCodeType": "",
"conditions": [
{
"fieldCode": "",
"fieldValue": ""
}
]
}
],
"effectiveDate": "",
"note": "",
"responseCode": ""
},
"order": {
"accountingCost": "",
"allowanceCharges": [
{}
],
"amountIncludingTax": "",
"attachments": [
{}
],
"delivery": {},
"deliveryTerms": {
"deliveryLocationId": "",
"incoterms": "",
"specialTerms": ""
},
"documentCurrencyCode": "",
"documentNumber": "",
"issueDate": "",
"issueTime": "",
"note": "",
"orderLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{}
],
"allowPartialDelivery": false,
"allowanceCharges": [
{}
],
"amountExcludingTax": "",
"baseQuantity": "",
"delivery": {
"deliveryLocation": {
"id": "",
"schemeId": ""
}
},
"description": "",
"itemPrice": "",
"lineId": "",
"lotNumberIds": [],
"name": "",
"note": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{}
],
"taxesDutiesFees": [
{}
]
}
],
"orderType": "",
"paymentTerms": {},
"references": [
{}
],
"sellerSupplierParty": {
"party": {},
"publicIdentifiers": [
{}
]
},
"taxSystem": "",
"timeZone": "",
"validityPeriod": ""
},
"rawDocumentData": {
"document": "",
"documentTypeId": "",
"parse": false,
"parseStrategy": "",
"processId": ""
}
},
"idempotencyGuid": "",
"legalEntityId": 0,
"receiveGuid": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
}
}'
import http.client
conn = http.client.HTTPSConnection("example.com")
payload = "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}"
headers = { 'content-type': "application/json" }
conn.request("POST", "/baseUrl/document_submissions", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/document_submissions"
payload = {
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": False
}
],
"createPrimaryImage": False,
"document": {
"documentType": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": { "party": { "contact": {} } },
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [{}]
}
],
"amountIncludingVat": "",
"attachments": [{}],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": False,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": { "party": {} },
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [{}]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": { "note": "" },
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [{}],
"salesOrderId": "",
"selfBillingMode": False,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [{}],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": False,
"x2y": ""
},
"invoiceResponse": {
"clarifications": [
{
"clarification": "",
"clarificationCode": "",
"clarificationCodeType": "",
"conditions": [
{
"fieldCode": "",
"fieldValue": ""
}
]
}
],
"effectiveDate": "",
"note": "",
"responseCode": ""
},
"order": {
"accountingCost": "",
"allowanceCharges": [{}],
"amountIncludingTax": "",
"attachments": [{}],
"delivery": {},
"deliveryTerms": {
"deliveryLocationId": "",
"incoterms": "",
"specialTerms": ""
},
"documentCurrencyCode": "",
"documentNumber": "",
"issueDate": "",
"issueTime": "",
"note": "",
"orderLines": [
{
"accountingCost": "",
"additionalItemProperties": [{}],
"allowPartialDelivery": False,
"allowanceCharges": [{}],
"amountExcludingTax": "",
"baseQuantity": "",
"delivery": { "deliveryLocation": {
"id": "",
"schemeId": ""
} },
"description": "",
"itemPrice": "",
"lineId": "",
"lotNumberIds": [],
"name": "",
"note": "",
"quantity": "",
"quantityUnitCode": "",
"references": [{}],
"taxesDutiesFees": [{}]
}
],
"orderType": "",
"paymentTerms": {},
"references": [{}],
"sellerSupplierParty": {
"party": {},
"publicIdentifiers": [{}]
},
"taxSystem": "",
"timeZone": "",
"validityPeriod": ""
},
"rawDocumentData": {
"document": "",
"documentTypeId": "",
"parse": False,
"parseStrategy": "",
"processId": ""
}
},
"idempotencyGuid": "",
"legalEntityId": 0,
"receiveGuid": "",
"routing": {
"clearWithoutSending": False,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
}
}
headers = {"content-type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.json())
library(httr)
url <- "{{baseUrl}}/document_submissions"
payload <- "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}"
encode <- "json"
response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/document_submissions")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}"
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
headers: {'Content-Type' => 'application/json'}
)
response = conn.post('/baseUrl/document_submissions') do |req|
req.body = "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": {\n \"documentType\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceResponse\": {\n \"clarifications\": [\n {\n \"clarification\": \"\",\n \"clarificationCode\": \"\",\n \"clarificationCodeType\": \"\",\n \"conditions\": [\n {\n \"fieldCode\": \"\",\n \"fieldValue\": \"\"\n }\n ]\n }\n ],\n \"effectiveDate\": \"\",\n \"note\": \"\",\n \"responseCode\": \"\"\n },\n \"order\": {\n \"accountingCost\": \"\",\n \"allowanceCharges\": [\n {}\n ],\n \"amountIncludingTax\": \"\",\n \"attachments\": [\n {}\n ],\n \"delivery\": {},\n \"deliveryTerms\": {\n \"deliveryLocationId\": \"\",\n \"incoterms\": \"\",\n \"specialTerms\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"documentNumber\": \"\",\n \"issueDate\": \"\",\n \"issueTime\": \"\",\n \"note\": \"\",\n \"orderLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {}\n ],\n \"allowPartialDelivery\": false,\n \"allowanceCharges\": [\n {}\n ],\n \"amountExcludingTax\": \"\",\n \"baseQuantity\": \"\",\n \"delivery\": {\n \"deliveryLocation\": {\n \"id\": \"\",\n \"schemeId\": \"\"\n }\n },\n \"description\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"lotNumberIds\": [],\n \"name\": \"\",\n \"note\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {}\n ],\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"orderType\": \"\",\n \"paymentTerms\": {},\n \"references\": [\n {}\n ],\n \"sellerSupplierParty\": {\n \"party\": {},\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"taxSystem\": \"\",\n \"timeZone\": \"\",\n \"validityPeriod\": \"\"\n },\n \"rawDocumentData\": {\n \"document\": \"\",\n \"documentTypeId\": \"\",\n \"parse\": false,\n \"parseStrategy\": \"\",\n \"processId\": \"\"\n }\n },\n \"idempotencyGuid\": \"\",\n \"legalEntityId\": 0,\n \"receiveGuid\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n }\n}"
end
puts response.status
puts response.body
use serde_json::json;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/document_submissions";
let payload = json!({
"attachments": (
json!({
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
})
),
"createPrimaryImage": false,
"document": json!({
"documentType": "",
"invoice": json!({
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": json!({
"party": json!({
"address": json!({
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
}),
"companyName": "",
"contact": json!({
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
})
}),
"publicIdentifiers": (
json!({
"id": "",
"scheme": ""
})
)
}),
"accountingSupplierParty": json!({"party": json!({"contact": json!({})})}),
"allowanceCharges": (
json!({
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": json!({
"amount": "",
"category": "",
"country": "",
"percentage": ""
}),
"taxesDutiesFees": (json!({}))
})
),
"amountIncludingVat": "",
"attachments": (json!({})),
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": json!({
"actualDate": "",
"deliveryLocation": json!({
"address": json!({}),
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
}),
"deliveryParty": json!({"party": json!({})}),
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
}),
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": (
json!({
"accountingCost": "",
"additionalItemProperties": (
json!({
"name": "",
"value": ""
})
),
"allowanceCharge": "",
"allowanceCharges": (
json!({
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
})
),
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": (
json!({
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
})
),
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": json!({}),
"taxesDutiesFees": (json!({}))
})
),
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": (),
"note": "",
"orderReference": "",
"paymentMeansArray": (
json!({
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
})
),
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": json!({"note": ""}),
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": (json!({})),
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": (
json!({
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
})
),
"taxSystem": "",
"taxesDutiesFees": (json!({})),
"transactionType": "",
"ublExtensions": (),
"vatReverseCharge": false,
"x2y": ""
}),
"invoiceResponse": json!({
"clarifications": (
json!({
"clarification": "",
"clarificationCode": "",
"clarificationCodeType": "",
"conditions": (
json!({
"fieldCode": "",
"fieldValue": ""
})
)
})
),
"effectiveDate": "",
"note": "",
"responseCode": ""
}),
"order": json!({
"accountingCost": "",
"allowanceCharges": (json!({})),
"amountIncludingTax": "",
"attachments": (json!({})),
"delivery": json!({}),
"deliveryTerms": json!({
"deliveryLocationId": "",
"incoterms": "",
"specialTerms": ""
}),
"documentCurrencyCode": "",
"documentNumber": "",
"issueDate": "",
"issueTime": "",
"note": "",
"orderLines": (
json!({
"accountingCost": "",
"additionalItemProperties": (json!({})),
"allowPartialDelivery": false,
"allowanceCharges": (json!({})),
"amountExcludingTax": "",
"baseQuantity": "",
"delivery": json!({"deliveryLocation": json!({
"id": "",
"schemeId": ""
})}),
"description": "",
"itemPrice": "",
"lineId": "",
"lotNumberIds": (),
"name": "",
"note": "",
"quantity": "",
"quantityUnitCode": "",
"references": (json!({})),
"taxesDutiesFees": (json!({}))
})
),
"orderType": "",
"paymentTerms": json!({}),
"references": (json!({})),
"sellerSupplierParty": json!({
"party": json!({}),
"publicIdentifiers": (json!({}))
}),
"taxSystem": "",
"timeZone": "",
"validityPeriod": ""
}),
"rawDocumentData": json!({
"document": "",
"documentTypeId": "",
"parse": false,
"parseStrategy": "",
"processId": ""
})
}),
"idempotencyGuid": "",
"legalEntityId": 0,
"receiveGuid": "",
"routing": json!({
"clearWithoutSending": false,
"eIdentifiers": (
json!({
"id": "",
"scheme": ""
})
),
"emails": ()
})
});
let mut headers = reqwest::header::HeaderMap::new();
headers.insert("content-type", "application/json".parse().unwrap());
let client = reqwest::Client::new();
let response = client.post(url)
.headers(headers)
.json(&payload)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request POST \
--url {{baseUrl}}/document_submissions \
--header 'content-type: application/json' \
--data '{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": {
"documentType": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceResponse": {
"clarifications": [
{
"clarification": "",
"clarificationCode": "",
"clarificationCodeType": "",
"conditions": [
{
"fieldCode": "",
"fieldValue": ""
}
]
}
],
"effectiveDate": "",
"note": "",
"responseCode": ""
},
"order": {
"accountingCost": "",
"allowanceCharges": [
{}
],
"amountIncludingTax": "",
"attachments": [
{}
],
"delivery": {},
"deliveryTerms": {
"deliveryLocationId": "",
"incoterms": "",
"specialTerms": ""
},
"documentCurrencyCode": "",
"documentNumber": "",
"issueDate": "",
"issueTime": "",
"note": "",
"orderLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{}
],
"allowPartialDelivery": false,
"allowanceCharges": [
{}
],
"amountExcludingTax": "",
"baseQuantity": "",
"delivery": {
"deliveryLocation": {
"id": "",
"schemeId": ""
}
},
"description": "",
"itemPrice": "",
"lineId": "",
"lotNumberIds": [],
"name": "",
"note": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{}
],
"taxesDutiesFees": [
{}
]
}
],
"orderType": "",
"paymentTerms": {},
"references": [
{}
],
"sellerSupplierParty": {
"party": {},
"publicIdentifiers": [
{}
]
},
"taxSystem": "",
"timeZone": "",
"validityPeriod": ""
},
"rawDocumentData": {
"document": "",
"documentTypeId": "",
"parse": false,
"parseStrategy": "",
"processId": ""
}
},
"idempotencyGuid": "",
"legalEntityId": 0,
"receiveGuid": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
}
}'
echo '{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": {
"documentType": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceResponse": {
"clarifications": [
{
"clarification": "",
"clarificationCode": "",
"clarificationCodeType": "",
"conditions": [
{
"fieldCode": "",
"fieldValue": ""
}
]
}
],
"effectiveDate": "",
"note": "",
"responseCode": ""
},
"order": {
"accountingCost": "",
"allowanceCharges": [
{}
],
"amountIncludingTax": "",
"attachments": [
{}
],
"delivery": {},
"deliveryTerms": {
"deliveryLocationId": "",
"incoterms": "",
"specialTerms": ""
},
"documentCurrencyCode": "",
"documentNumber": "",
"issueDate": "",
"issueTime": "",
"note": "",
"orderLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{}
],
"allowPartialDelivery": false,
"allowanceCharges": [
{}
],
"amountExcludingTax": "",
"baseQuantity": "",
"delivery": {
"deliveryLocation": {
"id": "",
"schemeId": ""
}
},
"description": "",
"itemPrice": "",
"lineId": "",
"lotNumberIds": [],
"name": "",
"note": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{}
],
"taxesDutiesFees": [
{}
]
}
],
"orderType": "",
"paymentTerms": {},
"references": [
{}
],
"sellerSupplierParty": {
"party": {},
"publicIdentifiers": [
{}
]
},
"taxSystem": "",
"timeZone": "",
"validityPeriod": ""
},
"rawDocumentData": {
"document": "",
"documentTypeId": "",
"parse": false,
"parseStrategy": "",
"processId": ""
}
},
"idempotencyGuid": "",
"legalEntityId": 0,
"receiveGuid": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
}
}' | \
http POST {{baseUrl}}/document_submissions \
content-type:application/json
wget --quiet \
--method POST \
--header 'content-type: application/json' \
--body-data '{\n "attachments": [\n {\n "description": "",\n "document": "",\n "documentId": "",\n "filename": "",\n "mimeType": "",\n "primaryImage": false\n }\n ],\n "createPrimaryImage": false,\n "document": {\n "documentType": "",\n "invoice": {\n "accountingCost": "",\n "accountingCurrencyTaxAmount": "",\n "accountingCurrencyTaxAmountCurrency": "",\n "accountingCustomerParty": {\n "party": {\n "address": {\n "city": "",\n "country": "",\n "county": "",\n "street1": "",\n "street2": "",\n "zip": ""\n },\n "companyName": "",\n "contact": {\n "email": "",\n "firstName": "",\n "id": "",\n "lastName": "",\n "phone": ""\n }\n },\n "publicIdentifiers": [\n {\n "id": "",\n "scheme": ""\n }\n ]\n },\n "accountingSupplierParty": {\n "party": {\n "contact": {}\n }\n },\n "allowanceCharges": [\n {\n "amountExcludingTax": "",\n "amountExcludingVat": "",\n "amountIncludingTax": "",\n "baseAmountExcludingTax": "",\n "baseAmountIncludingTax": "",\n "reason": "",\n "reasonCode": "",\n "tax": {\n "amount": "",\n "category": "",\n "country": "",\n "percentage": ""\n },\n "taxesDutiesFees": [\n {}\n ]\n }\n ],\n "amountIncludingVat": "",\n "attachments": [\n {}\n ],\n "billingReference": "",\n "buyerReference": "",\n "consumerTaxMode": false,\n "contractDocumentReference": "",\n "delivery": {\n "actualDate": "",\n "deliveryLocation": {\n "address": {},\n "id": "",\n "locationName": "",\n "schemeAgencyId": "",\n "schemeId": ""\n },\n "deliveryParty": {\n "party": {}\n },\n "deliveryPartyName": "",\n "quantity": "",\n "requestedDeliveryPeriod": "",\n "shippingMarks": ""\n },\n "documentCurrencyCode": "",\n "dueDate": "",\n "invoiceLines": [\n {\n "accountingCost": "",\n "additionalItemProperties": [\n {\n "name": "",\n "value": ""\n }\n ],\n "allowanceCharge": "",\n "allowanceCharges": [\n {\n "amountExcludingTax": "",\n "baseAmountExcludingTax": "",\n "reason": "",\n "reasonCode": ""\n }\n ],\n "amountExcludingTax": "",\n "amountExcludingVat": "",\n "amountIncludingTax": "",\n "buyersItemIdentification": "",\n "description": "",\n "invoicePeriod": "",\n "itemPrice": "",\n "lineId": "",\n "name": "",\n "note": "",\n "orderLineReferenceLineId": "",\n "quantity": "",\n "quantityUnitCode": "",\n "references": [\n {\n "documentId": "",\n "documentType": "",\n "issueDate": "",\n "lineId": ""\n }\n ],\n "sellersItemIdentification": "",\n "standardItemIdentification": "",\n "standardItemIdentificationSchemeAgencyId": "",\n "standardItemIdentificationSchemeId": "",\n "tax": {},\n "taxesDutiesFees": [\n {}\n ]\n }\n ],\n "invoiceNumber": "",\n "invoicePeriod": "",\n "invoiceType": "",\n "issueDate": "",\n "issueReasons": [],\n "note": "",\n "orderReference": "",\n "paymentMeansArray": [\n {\n "account": "",\n "amount": "",\n "branche_code": "",\n "code": "",\n "holder": "",\n "mandate": "",\n "network": "",\n "paymentId": ""\n }\n ],\n "paymentMeansBic": "",\n "paymentMeansCode": "",\n "paymentMeansIban": "",\n "paymentMeansPaymentId": "",\n "paymentTerms": {\n "note": ""\n },\n "preferredInvoiceType": "",\n "prepaidAmount": "",\n "priceMode": "",\n "projectReference": "",\n "references": [\n {}\n ],\n "salesOrderId": "",\n "selfBillingMode": false,\n "taxExemptReason": "",\n "taxPointDate": "",\n "taxSubtotals": [\n {\n "category": "",\n "country": "",\n "percentage": "",\n "taxAmount": "",\n "taxableAmount": ""\n }\n ],\n "taxSystem": "",\n "taxesDutiesFees": [\n {}\n ],\n "transactionType": "",\n "ublExtensions": [],\n "vatReverseCharge": false,\n "x2y": ""\n },\n "invoiceResponse": {\n "clarifications": [\n {\n "clarification": "",\n "clarificationCode": "",\n "clarificationCodeType": "",\n "conditions": [\n {\n "fieldCode": "",\n "fieldValue": ""\n }\n ]\n }\n ],\n "effectiveDate": "",\n "note": "",\n "responseCode": ""\n },\n "order": {\n "accountingCost": "",\n "allowanceCharges": [\n {}\n ],\n "amountIncludingTax": "",\n "attachments": [\n {}\n ],\n "delivery": {},\n "deliveryTerms": {\n "deliveryLocationId": "",\n "incoterms": "",\n "specialTerms": ""\n },\n "documentCurrencyCode": "",\n "documentNumber": "",\n "issueDate": "",\n "issueTime": "",\n "note": "",\n "orderLines": [\n {\n "accountingCost": "",\n "additionalItemProperties": [\n {}\n ],\n "allowPartialDelivery": false,\n "allowanceCharges": [\n {}\n ],\n "amountExcludingTax": "",\n "baseQuantity": "",\n "delivery": {\n "deliveryLocation": {\n "id": "",\n "schemeId": ""\n }\n },\n "description": "",\n "itemPrice": "",\n "lineId": "",\n "lotNumberIds": [],\n "name": "",\n "note": "",\n "quantity": "",\n "quantityUnitCode": "",\n "references": [\n {}\n ],\n "taxesDutiesFees": [\n {}\n ]\n }\n ],\n "orderType": "",\n "paymentTerms": {},\n "references": [\n {}\n ],\n "sellerSupplierParty": {\n "party": {},\n "publicIdentifiers": [\n {}\n ]\n },\n "taxSystem": "",\n "timeZone": "",\n "validityPeriod": ""\n },\n "rawDocumentData": {\n "document": "",\n "documentTypeId": "",\n "parse": false,\n "parseStrategy": "",\n "processId": ""\n }\n },\n "idempotencyGuid": "",\n "legalEntityId": 0,\n "receiveGuid": "",\n "routing": {\n "clearWithoutSending": false,\n "eIdentifiers": [\n {\n "id": "",\n "scheme": ""\n }\n ],\n "emails": []\n }\n}' \
--output-document \
- {{baseUrl}}/document_submissions
import Foundation
let headers = ["content-type": "application/json"]
let parameters = [
"attachments": [
[
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
]
],
"createPrimaryImage": false,
"document": [
"documentType": "",
"invoice": [
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": [
"party": [
"address": [
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
],
"companyName": "",
"contact": [
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
]
],
"publicIdentifiers": [
[
"id": "",
"scheme": ""
]
]
],
"accountingSupplierParty": ["party": ["contact": []]],
"allowanceCharges": [
[
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": [
"amount": "",
"category": "",
"country": "",
"percentage": ""
],
"taxesDutiesFees": [[]]
]
],
"amountIncludingVat": "",
"attachments": [[]],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": [
"actualDate": "",
"deliveryLocation": [
"address": [],
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
],
"deliveryParty": ["party": []],
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
],
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
[
"accountingCost": "",
"additionalItemProperties": [
[
"name": "",
"value": ""
]
],
"allowanceCharge": "",
"allowanceCharges": [
[
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
]
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
[
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
]
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": [],
"taxesDutiesFees": [[]]
]
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
[
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
]
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": ["note": ""],
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [[]],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
[
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
]
],
"taxSystem": "",
"taxesDutiesFees": [[]],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
],
"invoiceResponse": [
"clarifications": [
[
"clarification": "",
"clarificationCode": "",
"clarificationCodeType": "",
"conditions": [
[
"fieldCode": "",
"fieldValue": ""
]
]
]
],
"effectiveDate": "",
"note": "",
"responseCode": ""
],
"order": [
"accountingCost": "",
"allowanceCharges": [[]],
"amountIncludingTax": "",
"attachments": [[]],
"delivery": [],
"deliveryTerms": [
"deliveryLocationId": "",
"incoterms": "",
"specialTerms": ""
],
"documentCurrencyCode": "",
"documentNumber": "",
"issueDate": "",
"issueTime": "",
"note": "",
"orderLines": [
[
"accountingCost": "",
"additionalItemProperties": [[]],
"allowPartialDelivery": false,
"allowanceCharges": [[]],
"amountExcludingTax": "",
"baseQuantity": "",
"delivery": ["deliveryLocation": [
"id": "",
"schemeId": ""
]],
"description": "",
"itemPrice": "",
"lineId": "",
"lotNumberIds": [],
"name": "",
"note": "",
"quantity": "",
"quantityUnitCode": "",
"references": [[]],
"taxesDutiesFees": [[]]
]
],
"orderType": "",
"paymentTerms": [],
"references": [[]],
"sellerSupplierParty": [
"party": [],
"publicIdentifiers": [[]]
],
"taxSystem": "",
"timeZone": "",
"validityPeriod": ""
],
"rawDocumentData": [
"document": "",
"documentTypeId": "",
"parse": false,
"parseStrategy": "",
"processId": ""
]
],
"idempotencyGuid": "",
"legalEntityId": 0,
"receiveGuid": "",
"routing": [
"clearWithoutSending": false,
"eIdentifiers": [
[
"id": "",
"scheme": ""
]
],
"emails": []
]
] as [String : Any]
let postData = JSONSerialization.data(withJSONObject: parameters, options: [])
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/document_submissions")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
GET
DEPRECATED. Get InvoiceSubmission Evidence
{{baseUrl}}/invoice_submissions/:guid/evidence
QUERY PARAMS
guid
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/invoice_submissions/:guid/evidence");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/get "{{baseUrl}}/invoice_submissions/:guid/evidence")
require "http/client"
url = "{{baseUrl}}/invoice_submissions/:guid/evidence"
response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("{{baseUrl}}/invoice_submissions/:guid/evidence"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/invoice_submissions/:guid/evidence");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/invoice_submissions/:guid/evidence"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /baseUrl/invoice_submissions/:guid/evidence HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/invoice_submissions/:guid/evidence")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/invoice_submissions/:guid/evidence"))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/invoice_submissions/:guid/evidence")
.get()
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/invoice_submissions/:guid/evidence")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('GET', '{{baseUrl}}/invoice_submissions/:guid/evidence');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'GET',
url: '{{baseUrl}}/invoice_submissions/:guid/evidence'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/invoice_submissions/:guid/evidence';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/invoice_submissions/:guid/evidence',
method: 'GET',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/invoice_submissions/:guid/evidence")
.get()
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'GET',
hostname: 'example.com',
port: null,
path: '/baseUrl/invoice_submissions/:guid/evidence',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'GET',
url: '{{baseUrl}}/invoice_submissions/:guid/evidence'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('GET', '{{baseUrl}}/invoice_submissions/:guid/evidence');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'GET',
url: '{{baseUrl}}/invoice_submissions/:guid/evidence'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/invoice_submissions/:guid/evidence';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/invoice_submissions/:guid/evidence"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/invoice_submissions/:guid/evidence" in
Client.call `GET uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/invoice_submissions/:guid/evidence",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('GET', '{{baseUrl}}/invoice_submissions/:guid/evidence');
echo $response->getBody();
setUrl('{{baseUrl}}/invoice_submissions/:guid/evidence');
$request->setMethod(HTTP_METH_GET);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/invoice_submissions/:guid/evidence');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/invoice_submissions/:guid/evidence' -Method GET
$response = Invoke-RestMethod -Uri '{{baseUrl}}/invoice_submissions/:guid/evidence' -Method GET
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("GET", "/baseUrl/invoice_submissions/:guid/evidence")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/invoice_submissions/:guid/evidence"
response = requests.get(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/invoice_submissions/:guid/evidence"
response <- VERB("GET", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/invoice_submissions/:guid/evidence")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.get('/baseUrl/invoice_submissions/:guid/evidence') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/invoice_submissions/:guid/evidence";
let client = reqwest::Client::new();
let response = client.get(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request GET \
--url {{baseUrl}}/invoice_submissions/:guid/evidence
http GET {{baseUrl}}/invoice_submissions/:guid/evidence
wget --quiet \
--method GET \
--output-document \
- {{baseUrl}}/invoice_submissions/:guid/evidence
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/invoice_submissions/:guid/evidence")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "GET"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
POST
DEPRECATED. Preflight an invoice recipient
{{baseUrl}}/invoice_submissions/preflight
BODY json
{
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
}
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/invoice_submissions/preflight");
struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);
curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/post "{{baseUrl}}/invoice_submissions/preflight" {:content-type :json
:form-params {:publicIdentifiers [{:id ""
:scheme ""}]}})
require "http/client"
url = "{{baseUrl}}/invoice_submissions/preflight"
headers = HTTP::Headers{
"content-type" => "application/json"
}
reqBody = "{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}"
response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("{{baseUrl}}/invoice_submissions/preflight"),
Content = new StringContent("{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/invoice_submissions/preflight");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/invoice_submissions/preflight"
payload := strings.NewReader("{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /baseUrl/invoice_submissions/preflight HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 79
{
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/invoice_submissions/preflight")
.setHeader("content-type", "application/json")
.setBody("{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/invoice_submissions/preflight"))
.header("content-type", "application/json")
.method("POST", HttpRequest.BodyPublishers.ofString("{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}"))
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}");
Request request = new Request.Builder()
.url("{{baseUrl}}/invoice_submissions/preflight")
.post(body)
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/invoice_submissions/preflight")
.header("content-type", "application/json")
.body("{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}")
.asString();
const data = JSON.stringify({
publicIdentifiers: [
{
id: '',
scheme: ''
}
]
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('POST', '{{baseUrl}}/invoice_submissions/preflight');
xhr.setRequestHeader('content-type', 'application/json');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'POST',
url: '{{baseUrl}}/invoice_submissions/preflight',
headers: {'content-type': 'application/json'},
data: {publicIdentifiers: [{id: '', scheme: ''}]}
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/invoice_submissions/preflight';
const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: '{"publicIdentifiers":[{"id":"","scheme":""}]}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/invoice_submissions/preflight',
method: 'POST',
headers: {
'content-type': 'application/json'
},
processData: false,
data: '{\n "publicIdentifiers": [\n {\n "id": "",\n "scheme": ""\n }\n ]\n}'
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}")
val request = Request.Builder()
.url("{{baseUrl}}/invoice_submissions/preflight")
.post(body)
.addHeader("content-type", "application/json")
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'POST',
hostname: 'example.com',
port: null,
path: '/baseUrl/invoice_submissions/preflight',
headers: {
'content-type': 'application/json'
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({publicIdentifiers: [{id: '', scheme: ''}]}));
req.end();
const request = require('request');
const options = {
method: 'POST',
url: '{{baseUrl}}/invoice_submissions/preflight',
headers: {'content-type': 'application/json'},
body: {publicIdentifiers: [{id: '', scheme: ''}]},
json: true
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('POST', '{{baseUrl}}/invoice_submissions/preflight');
req.headers({
'content-type': 'application/json'
});
req.type('json');
req.send({
publicIdentifiers: [
{
id: '',
scheme: ''
}
]
});
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'POST',
url: '{{baseUrl}}/invoice_submissions/preflight',
headers: {'content-type': 'application/json'},
data: {publicIdentifiers: [{id: '', scheme: ''}]}
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/invoice_submissions/preflight';
const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: '{"publicIdentifiers":[{"id":"","scheme":""}]}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"publicIdentifiers": @[ @{ @"id": @"", @"scheme": @"" } ] };
NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/invoice_submissions/preflight"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/invoice_submissions/preflight" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}" in
Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/invoice_submissions/preflight",
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([
'publicIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
]
]),
CURLOPT_HTTPHEADER => [
"content-type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('POST', '{{baseUrl}}/invoice_submissions/preflight', [
'body' => '{
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
}',
'headers' => [
'content-type' => 'application/json',
],
]);
echo $response->getBody();
setUrl('{{baseUrl}}/invoice_submissions/preflight');
$request->setMethod(HTTP_METH_POST);
$request->setHeaders([
'content-type' => 'application/json'
]);
$request->setContentType('application/json');
$request->setBody(json_encode([
'publicIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
]
]));
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
append(json_encode([
'publicIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
]
]));
$request->setRequestUrl('{{baseUrl}}/invoice_submissions/preflight');
$request->setRequestMethod('POST');
$request->setBody($body);
$request->setHeaders([
'content-type' => 'application/json'
]);
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/invoice_submissions/preflight' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/invoice_submissions/preflight' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
}'
import http.client
conn = http.client.HTTPSConnection("example.com")
payload = "{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}"
headers = { 'content-type': "application/json" }
conn.request("POST", "/baseUrl/invoice_submissions/preflight", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/invoice_submissions/preflight"
payload = { "publicIdentifiers": [
{
"id": "",
"scheme": ""
}
] }
headers = {"content-type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.json())
library(httr)
url <- "{{baseUrl}}/invoice_submissions/preflight"
payload <- "{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}"
encode <- "json"
response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/invoice_submissions/preflight")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
headers: {'Content-Type' => 'application/json'}
)
response = conn.post('/baseUrl/invoice_submissions/preflight') do |req|
req.body = "{\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n}"
end
puts response.status
puts response.body
use serde_json::json;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/invoice_submissions/preflight";
let payload = json!({"publicIdentifiers": (
json!({
"id": "",
"scheme": ""
})
)});
let mut headers = reqwest::header::HeaderMap::new();
headers.insert("content-type", "application/json".parse().unwrap());
let client = reqwest::Client::new();
let response = client.post(url)
.headers(headers)
.json(&payload)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request POST \
--url {{baseUrl}}/invoice_submissions/preflight \
--header 'content-type: application/json' \
--data '{
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
}'
echo '{
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
}' | \
http POST {{baseUrl}}/invoice_submissions/preflight \
content-type:application/json
wget --quiet \
--method POST \
--header 'content-type: application/json' \
--body-data '{\n "publicIdentifiers": [\n {\n "id": "",\n "scheme": ""\n }\n ]\n}' \
--output-document \
- {{baseUrl}}/invoice_submissions/preflight
import Foundation
let headers = ["content-type": "application/json"]
let parameters = ["publicIdentifiers": [
[
"id": "",
"scheme": ""
]
]] as [String : Any]
let postData = JSONSerialization.data(withJSONObject: parameters, options: [])
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/invoice_submissions/preflight")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
POST
Submit a new invoice
{{baseUrl}}/invoice_submissions
BODY json
{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": "",
"documentUrl": "",
"idempotencyGuid": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceData": {
"conversionStrategy": "",
"document": ""
},
"invoiceRecipient": {
"emails": [],
"publicIdentifiers": [
{}
]
},
"legalEntityId": 0,
"legalSupplierId": 0,
"mode": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
},
"supplierId": 0
}
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/invoice_submissions");
struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);
curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/post "{{baseUrl}}/invoice_submissions" {:content-type :json
:form-params {:attachments [{:description ""
:document ""
:documentId ""
:filename ""
:mimeType ""
:primaryImage false}]
:createPrimaryImage false
:document ""
:documentUrl ""
:idempotencyGuid ""
:invoice {:accountingCost ""
:accountingCurrencyTaxAmount ""
:accountingCurrencyTaxAmountCurrency ""
:accountingCustomerParty {:party {:address {:city ""
:country ""
:county ""
:street1 ""
:street2 ""
:zip ""}
:companyName ""
:contact {:email ""
:firstName ""
:id ""
:lastName ""
:phone ""}}
:publicIdentifiers [{:id ""
:scheme ""}]}
:accountingSupplierParty {:party {:contact {}}}
:allowanceCharges [{:amountExcludingTax ""
:amountExcludingVat ""
:amountIncludingTax ""
:baseAmountExcludingTax ""
:baseAmountIncludingTax ""
:reason ""
:reasonCode ""
:tax {:amount ""
:category ""
:country ""
:percentage ""}
:taxesDutiesFees [{}]}]
:amountIncludingVat ""
:attachments [{}]
:billingReference ""
:buyerReference ""
:consumerTaxMode false
:contractDocumentReference ""
:delivery {:actualDate ""
:deliveryLocation {:address {}
:id ""
:locationName ""
:schemeAgencyId ""
:schemeId ""}
:deliveryParty {:party {}}
:deliveryPartyName ""
:quantity ""
:requestedDeliveryPeriod ""
:shippingMarks ""}
:documentCurrencyCode ""
:dueDate ""
:invoiceLines [{:accountingCost ""
:additionalItemProperties [{:name ""
:value ""}]
:allowanceCharge ""
:allowanceCharges [{:amountExcludingTax ""
:baseAmountExcludingTax ""
:reason ""
:reasonCode ""}]
:amountExcludingTax ""
:amountExcludingVat ""
:amountIncludingTax ""
:buyersItemIdentification ""
:description ""
:invoicePeriod ""
:itemPrice ""
:lineId ""
:name ""
:note ""
:orderLineReferenceLineId ""
:quantity ""
:quantityUnitCode ""
:references [{:documentId ""
:documentType ""
:issueDate ""
:lineId ""}]
:sellersItemIdentification ""
:standardItemIdentification ""
:standardItemIdentificationSchemeAgencyId ""
:standardItemIdentificationSchemeId ""
:tax {}
:taxesDutiesFees [{}]}]
:invoiceNumber ""
:invoicePeriod ""
:invoiceType ""
:issueDate ""
:issueReasons []
:note ""
:orderReference ""
:paymentMeansArray [{:account ""
:amount ""
:branche_code ""
:code ""
:holder ""
:mandate ""
:network ""
:paymentId ""}]
:paymentMeansBic ""
:paymentMeansCode ""
:paymentMeansIban ""
:paymentMeansPaymentId ""
:paymentTerms {:note ""}
:preferredInvoiceType ""
:prepaidAmount ""
:priceMode ""
:projectReference ""
:references [{}]
:salesOrderId ""
:selfBillingMode false
:taxExemptReason ""
:taxPointDate ""
:taxSubtotals [{:category ""
:country ""
:percentage ""
:taxAmount ""
:taxableAmount ""}]
:taxSystem ""
:taxesDutiesFees [{}]
:transactionType ""
:ublExtensions []
:vatReverseCharge false
:x2y ""}
:invoiceData {:conversionStrategy ""
:document ""}
:invoiceRecipient {:emails []
:publicIdentifiers [{}]}
:legalEntityId 0
:legalSupplierId 0
:mode ""
:routing {:clearWithoutSending false
:eIdentifiers [{:id ""
:scheme ""}]
:emails []}
:supplierId 0}})
require "http/client"
url = "{{baseUrl}}/invoice_submissions"
headers = HTTP::Headers{
"content-type" => "application/json"
}
reqBody = "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}"
response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("{{baseUrl}}/invoice_submissions"),
Content = new StringContent("{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/invoice_submissions");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/invoice_submissions"
payload := strings.NewReader("{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /baseUrl/invoice_submissions HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 4857
{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": "",
"documentUrl": "",
"idempotencyGuid": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceData": {
"conversionStrategy": "",
"document": ""
},
"invoiceRecipient": {
"emails": [],
"publicIdentifiers": [
{}
]
},
"legalEntityId": 0,
"legalSupplierId": 0,
"mode": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
},
"supplierId": 0
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/invoice_submissions")
.setHeader("content-type", "application/json")
.setBody("{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/invoice_submissions"))
.header("content-type", "application/json")
.method("POST", HttpRequest.BodyPublishers.ofString("{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}"))
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}");
Request request = new Request.Builder()
.url("{{baseUrl}}/invoice_submissions")
.post(body)
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/invoice_submissions")
.header("content-type", "application/json")
.body("{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}")
.asString();
const data = JSON.stringify({
attachments: [
{
description: '',
document: '',
documentId: '',
filename: '',
mimeType: '',
primaryImage: false
}
],
createPrimaryImage: false,
document: '',
documentUrl: '',
idempotencyGuid: '',
invoice: {
accountingCost: '',
accountingCurrencyTaxAmount: '',
accountingCurrencyTaxAmountCurrency: '',
accountingCustomerParty: {
party: {
address: {
city: '',
country: '',
county: '',
street1: '',
street2: '',
zip: ''
},
companyName: '',
contact: {
email: '',
firstName: '',
id: '',
lastName: '',
phone: ''
}
},
publicIdentifiers: [
{
id: '',
scheme: ''
}
]
},
accountingSupplierParty: {
party: {
contact: {}
}
},
allowanceCharges: [
{
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
baseAmountExcludingTax: '',
baseAmountIncludingTax: '',
reason: '',
reasonCode: '',
tax: {
amount: '',
category: '',
country: '',
percentage: ''
},
taxesDutiesFees: [
{}
]
}
],
amountIncludingVat: '',
attachments: [
{}
],
billingReference: '',
buyerReference: '',
consumerTaxMode: false,
contractDocumentReference: '',
delivery: {
actualDate: '',
deliveryLocation: {
address: {},
id: '',
locationName: '',
schemeAgencyId: '',
schemeId: ''
},
deliveryParty: {
party: {}
},
deliveryPartyName: '',
quantity: '',
requestedDeliveryPeriod: '',
shippingMarks: ''
},
documentCurrencyCode: '',
dueDate: '',
invoiceLines: [
{
accountingCost: '',
additionalItemProperties: [
{
name: '',
value: ''
}
],
allowanceCharge: '',
allowanceCharges: [
{
amountExcludingTax: '',
baseAmountExcludingTax: '',
reason: '',
reasonCode: ''
}
],
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
buyersItemIdentification: '',
description: '',
invoicePeriod: '',
itemPrice: '',
lineId: '',
name: '',
note: '',
orderLineReferenceLineId: '',
quantity: '',
quantityUnitCode: '',
references: [
{
documentId: '',
documentType: '',
issueDate: '',
lineId: ''
}
],
sellersItemIdentification: '',
standardItemIdentification: '',
standardItemIdentificationSchemeAgencyId: '',
standardItemIdentificationSchemeId: '',
tax: {},
taxesDutiesFees: [
{}
]
}
],
invoiceNumber: '',
invoicePeriod: '',
invoiceType: '',
issueDate: '',
issueReasons: [],
note: '',
orderReference: '',
paymentMeansArray: [
{
account: '',
amount: '',
branche_code: '',
code: '',
holder: '',
mandate: '',
network: '',
paymentId: ''
}
],
paymentMeansBic: '',
paymentMeansCode: '',
paymentMeansIban: '',
paymentMeansPaymentId: '',
paymentTerms: {
note: ''
},
preferredInvoiceType: '',
prepaidAmount: '',
priceMode: '',
projectReference: '',
references: [
{}
],
salesOrderId: '',
selfBillingMode: false,
taxExemptReason: '',
taxPointDate: '',
taxSubtotals: [
{
category: '',
country: '',
percentage: '',
taxAmount: '',
taxableAmount: ''
}
],
taxSystem: '',
taxesDutiesFees: [
{}
],
transactionType: '',
ublExtensions: [],
vatReverseCharge: false,
x2y: ''
},
invoiceData: {
conversionStrategy: '',
document: ''
},
invoiceRecipient: {
emails: [],
publicIdentifiers: [
{}
]
},
legalEntityId: 0,
legalSupplierId: 0,
mode: '',
routing: {
clearWithoutSending: false,
eIdentifiers: [
{
id: '',
scheme: ''
}
],
emails: []
},
supplierId: 0
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('POST', '{{baseUrl}}/invoice_submissions');
xhr.setRequestHeader('content-type', 'application/json');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'POST',
url: '{{baseUrl}}/invoice_submissions',
headers: {'content-type': 'application/json'},
data: {
attachments: [
{
description: '',
document: '',
documentId: '',
filename: '',
mimeType: '',
primaryImage: false
}
],
createPrimaryImage: false,
document: '',
documentUrl: '',
idempotencyGuid: '',
invoice: {
accountingCost: '',
accountingCurrencyTaxAmount: '',
accountingCurrencyTaxAmountCurrency: '',
accountingCustomerParty: {
party: {
address: {city: '', country: '', county: '', street1: '', street2: '', zip: ''},
companyName: '',
contact: {email: '', firstName: '', id: '', lastName: '', phone: ''}
},
publicIdentifiers: [{id: '', scheme: ''}]
},
accountingSupplierParty: {party: {contact: {}}},
allowanceCharges: [
{
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
baseAmountExcludingTax: '',
baseAmountIncludingTax: '',
reason: '',
reasonCode: '',
tax: {amount: '', category: '', country: '', percentage: ''},
taxesDutiesFees: [{}]
}
],
amountIncludingVat: '',
attachments: [{}],
billingReference: '',
buyerReference: '',
consumerTaxMode: false,
contractDocumentReference: '',
delivery: {
actualDate: '',
deliveryLocation: {address: {}, id: '', locationName: '', schemeAgencyId: '', schemeId: ''},
deliveryParty: {party: {}},
deliveryPartyName: '',
quantity: '',
requestedDeliveryPeriod: '',
shippingMarks: ''
},
documentCurrencyCode: '',
dueDate: '',
invoiceLines: [
{
accountingCost: '',
additionalItemProperties: [{name: '', value: ''}],
allowanceCharge: '',
allowanceCharges: [
{amountExcludingTax: '', baseAmountExcludingTax: '', reason: '', reasonCode: ''}
],
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
buyersItemIdentification: '',
description: '',
invoicePeriod: '',
itemPrice: '',
lineId: '',
name: '',
note: '',
orderLineReferenceLineId: '',
quantity: '',
quantityUnitCode: '',
references: [{documentId: '', documentType: '', issueDate: '', lineId: ''}],
sellersItemIdentification: '',
standardItemIdentification: '',
standardItemIdentificationSchemeAgencyId: '',
standardItemIdentificationSchemeId: '',
tax: {},
taxesDutiesFees: [{}]
}
],
invoiceNumber: '',
invoicePeriod: '',
invoiceType: '',
issueDate: '',
issueReasons: [],
note: '',
orderReference: '',
paymentMeansArray: [
{
account: '',
amount: '',
branche_code: '',
code: '',
holder: '',
mandate: '',
network: '',
paymentId: ''
}
],
paymentMeansBic: '',
paymentMeansCode: '',
paymentMeansIban: '',
paymentMeansPaymentId: '',
paymentTerms: {note: ''},
preferredInvoiceType: '',
prepaidAmount: '',
priceMode: '',
projectReference: '',
references: [{}],
salesOrderId: '',
selfBillingMode: false,
taxExemptReason: '',
taxPointDate: '',
taxSubtotals: [{category: '', country: '', percentage: '', taxAmount: '', taxableAmount: ''}],
taxSystem: '',
taxesDutiesFees: [{}],
transactionType: '',
ublExtensions: [],
vatReverseCharge: false,
x2y: ''
},
invoiceData: {conversionStrategy: '', document: ''},
invoiceRecipient: {emails: [], publicIdentifiers: [{}]},
legalEntityId: 0,
legalSupplierId: 0,
mode: '',
routing: {clearWithoutSending: false, eIdentifiers: [{id: '', scheme: ''}], emails: []},
supplierId: 0
}
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/invoice_submissions';
const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: '{"attachments":[{"description":"","document":"","documentId":"","filename":"","mimeType":"","primaryImage":false}],"createPrimaryImage":false,"document":"","documentUrl":"","idempotencyGuid":"","invoice":{"accountingCost":"","accountingCurrencyTaxAmount":"","accountingCurrencyTaxAmountCurrency":"","accountingCustomerParty":{"party":{"address":{"city":"","country":"","county":"","street1":"","street2":"","zip":""},"companyName":"","contact":{"email":"","firstName":"","id":"","lastName":"","phone":""}},"publicIdentifiers":[{"id":"","scheme":""}]},"accountingSupplierParty":{"party":{"contact":{}}},"allowanceCharges":[{"amountExcludingTax":"","amountExcludingVat":"","amountIncludingTax":"","baseAmountExcludingTax":"","baseAmountIncludingTax":"","reason":"","reasonCode":"","tax":{"amount":"","category":"","country":"","percentage":""},"taxesDutiesFees":[{}]}],"amountIncludingVat":"","attachments":[{}],"billingReference":"","buyerReference":"","consumerTaxMode":false,"contractDocumentReference":"","delivery":{"actualDate":"","deliveryLocation":{"address":{},"id":"","locationName":"","schemeAgencyId":"","schemeId":""},"deliveryParty":{"party":{}},"deliveryPartyName":"","quantity":"","requestedDeliveryPeriod":"","shippingMarks":""},"documentCurrencyCode":"","dueDate":"","invoiceLines":[{"accountingCost":"","additionalItemProperties":[{"name":"","value":""}],"allowanceCharge":"","allowanceCharges":[{"amountExcludingTax":"","baseAmountExcludingTax":"","reason":"","reasonCode":""}],"amountExcludingTax":"","amountExcludingVat":"","amountIncludingTax":"","buyersItemIdentification":"","description":"","invoicePeriod":"","itemPrice":"","lineId":"","name":"","note":"","orderLineReferenceLineId":"","quantity":"","quantityUnitCode":"","references":[{"documentId":"","documentType":"","issueDate":"","lineId":""}],"sellersItemIdentification":"","standardItemIdentification":"","standardItemIdentificationSchemeAgencyId":"","standardItemIdentificationSchemeId":"","tax":{},"taxesDutiesFees":[{}]}],"invoiceNumber":"","invoicePeriod":"","invoiceType":"","issueDate":"","issueReasons":[],"note":"","orderReference":"","paymentMeansArray":[{"account":"","amount":"","branche_code":"","code":"","holder":"","mandate":"","network":"","paymentId":""}],"paymentMeansBic":"","paymentMeansCode":"","paymentMeansIban":"","paymentMeansPaymentId":"","paymentTerms":{"note":""},"preferredInvoiceType":"","prepaidAmount":"","priceMode":"","projectReference":"","references":[{}],"salesOrderId":"","selfBillingMode":false,"taxExemptReason":"","taxPointDate":"","taxSubtotals":[{"category":"","country":"","percentage":"","taxAmount":"","taxableAmount":""}],"taxSystem":"","taxesDutiesFees":[{}],"transactionType":"","ublExtensions":[],"vatReverseCharge":false,"x2y":""},"invoiceData":{"conversionStrategy":"","document":""},"invoiceRecipient":{"emails":[],"publicIdentifiers":[{}]},"legalEntityId":0,"legalSupplierId":0,"mode":"","routing":{"clearWithoutSending":false,"eIdentifiers":[{"id":"","scheme":""}],"emails":[]},"supplierId":0}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/invoice_submissions',
method: 'POST',
headers: {
'content-type': 'application/json'
},
processData: false,
data: '{\n "attachments": [\n {\n "description": "",\n "document": "",\n "documentId": "",\n "filename": "",\n "mimeType": "",\n "primaryImage": false\n }\n ],\n "createPrimaryImage": false,\n "document": "",\n "documentUrl": "",\n "idempotencyGuid": "",\n "invoice": {\n "accountingCost": "",\n "accountingCurrencyTaxAmount": "",\n "accountingCurrencyTaxAmountCurrency": "",\n "accountingCustomerParty": {\n "party": {\n "address": {\n "city": "",\n "country": "",\n "county": "",\n "street1": "",\n "street2": "",\n "zip": ""\n },\n "companyName": "",\n "contact": {\n "email": "",\n "firstName": "",\n "id": "",\n "lastName": "",\n "phone": ""\n }\n },\n "publicIdentifiers": [\n {\n "id": "",\n "scheme": ""\n }\n ]\n },\n "accountingSupplierParty": {\n "party": {\n "contact": {}\n }\n },\n "allowanceCharges": [\n {\n "amountExcludingTax": "",\n "amountExcludingVat": "",\n "amountIncludingTax": "",\n "baseAmountExcludingTax": "",\n "baseAmountIncludingTax": "",\n "reason": "",\n "reasonCode": "",\n "tax": {\n "amount": "",\n "category": "",\n "country": "",\n "percentage": ""\n },\n "taxesDutiesFees": [\n {}\n ]\n }\n ],\n "amountIncludingVat": "",\n "attachments": [\n {}\n ],\n "billingReference": "",\n "buyerReference": "",\n "consumerTaxMode": false,\n "contractDocumentReference": "",\n "delivery": {\n "actualDate": "",\n "deliveryLocation": {\n "address": {},\n "id": "",\n "locationName": "",\n "schemeAgencyId": "",\n "schemeId": ""\n },\n "deliveryParty": {\n "party": {}\n },\n "deliveryPartyName": "",\n "quantity": "",\n "requestedDeliveryPeriod": "",\n "shippingMarks": ""\n },\n "documentCurrencyCode": "",\n "dueDate": "",\n "invoiceLines": [\n {\n "accountingCost": "",\n "additionalItemProperties": [\n {\n "name": "",\n "value": ""\n }\n ],\n "allowanceCharge": "",\n "allowanceCharges": [\n {\n "amountExcludingTax": "",\n "baseAmountExcludingTax": "",\n "reason": "",\n "reasonCode": ""\n }\n ],\n "amountExcludingTax": "",\n "amountExcludingVat": "",\n "amountIncludingTax": "",\n "buyersItemIdentification": "",\n "description": "",\n "invoicePeriod": "",\n "itemPrice": "",\n "lineId": "",\n "name": "",\n "note": "",\n "orderLineReferenceLineId": "",\n "quantity": "",\n "quantityUnitCode": "",\n "references": [\n {\n "documentId": "",\n "documentType": "",\n "issueDate": "",\n "lineId": ""\n }\n ],\n "sellersItemIdentification": "",\n "standardItemIdentification": "",\n "standardItemIdentificationSchemeAgencyId": "",\n "standardItemIdentificationSchemeId": "",\n "tax": {},\n "taxesDutiesFees": [\n {}\n ]\n }\n ],\n "invoiceNumber": "",\n "invoicePeriod": "",\n "invoiceType": "",\n "issueDate": "",\n "issueReasons": [],\n "note": "",\n "orderReference": "",\n "paymentMeansArray": [\n {\n "account": "",\n "amount": "",\n "branche_code": "",\n "code": "",\n "holder": "",\n "mandate": "",\n "network": "",\n "paymentId": ""\n }\n ],\n "paymentMeansBic": "",\n "paymentMeansCode": "",\n "paymentMeansIban": "",\n "paymentMeansPaymentId": "",\n "paymentTerms": {\n "note": ""\n },\n "preferredInvoiceType": "",\n "prepaidAmount": "",\n "priceMode": "",\n "projectReference": "",\n "references": [\n {}\n ],\n "salesOrderId": "",\n "selfBillingMode": false,\n "taxExemptReason": "",\n "taxPointDate": "",\n "taxSubtotals": [\n {\n "category": "",\n "country": "",\n "percentage": "",\n "taxAmount": "",\n "taxableAmount": ""\n }\n ],\n "taxSystem": "",\n "taxesDutiesFees": [\n {}\n ],\n "transactionType": "",\n "ublExtensions": [],\n "vatReverseCharge": false,\n "x2y": ""\n },\n "invoiceData": {\n "conversionStrategy": "",\n "document": ""\n },\n "invoiceRecipient": {\n "emails": [],\n "publicIdentifiers": [\n {}\n ]\n },\n "legalEntityId": 0,\n "legalSupplierId": 0,\n "mode": "",\n "routing": {\n "clearWithoutSending": false,\n "eIdentifiers": [\n {\n "id": "",\n "scheme": ""\n }\n ],\n "emails": []\n },\n "supplierId": 0\n}'
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}")
val request = Request.Builder()
.url("{{baseUrl}}/invoice_submissions")
.post(body)
.addHeader("content-type", "application/json")
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'POST',
hostname: 'example.com',
port: null,
path: '/baseUrl/invoice_submissions',
headers: {
'content-type': 'application/json'
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.write(JSON.stringify({
attachments: [
{
description: '',
document: '',
documentId: '',
filename: '',
mimeType: '',
primaryImage: false
}
],
createPrimaryImage: false,
document: '',
documentUrl: '',
idempotencyGuid: '',
invoice: {
accountingCost: '',
accountingCurrencyTaxAmount: '',
accountingCurrencyTaxAmountCurrency: '',
accountingCustomerParty: {
party: {
address: {city: '', country: '', county: '', street1: '', street2: '', zip: ''},
companyName: '',
contact: {email: '', firstName: '', id: '', lastName: '', phone: ''}
},
publicIdentifiers: [{id: '', scheme: ''}]
},
accountingSupplierParty: {party: {contact: {}}},
allowanceCharges: [
{
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
baseAmountExcludingTax: '',
baseAmountIncludingTax: '',
reason: '',
reasonCode: '',
tax: {amount: '', category: '', country: '', percentage: ''},
taxesDutiesFees: [{}]
}
],
amountIncludingVat: '',
attachments: [{}],
billingReference: '',
buyerReference: '',
consumerTaxMode: false,
contractDocumentReference: '',
delivery: {
actualDate: '',
deliveryLocation: {address: {}, id: '', locationName: '', schemeAgencyId: '', schemeId: ''},
deliveryParty: {party: {}},
deliveryPartyName: '',
quantity: '',
requestedDeliveryPeriod: '',
shippingMarks: ''
},
documentCurrencyCode: '',
dueDate: '',
invoiceLines: [
{
accountingCost: '',
additionalItemProperties: [{name: '', value: ''}],
allowanceCharge: '',
allowanceCharges: [
{amountExcludingTax: '', baseAmountExcludingTax: '', reason: '', reasonCode: ''}
],
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
buyersItemIdentification: '',
description: '',
invoicePeriod: '',
itemPrice: '',
lineId: '',
name: '',
note: '',
orderLineReferenceLineId: '',
quantity: '',
quantityUnitCode: '',
references: [{documentId: '', documentType: '', issueDate: '', lineId: ''}],
sellersItemIdentification: '',
standardItemIdentification: '',
standardItemIdentificationSchemeAgencyId: '',
standardItemIdentificationSchemeId: '',
tax: {},
taxesDutiesFees: [{}]
}
],
invoiceNumber: '',
invoicePeriod: '',
invoiceType: '',
issueDate: '',
issueReasons: [],
note: '',
orderReference: '',
paymentMeansArray: [
{
account: '',
amount: '',
branche_code: '',
code: '',
holder: '',
mandate: '',
network: '',
paymentId: ''
}
],
paymentMeansBic: '',
paymentMeansCode: '',
paymentMeansIban: '',
paymentMeansPaymentId: '',
paymentTerms: {note: ''},
preferredInvoiceType: '',
prepaidAmount: '',
priceMode: '',
projectReference: '',
references: [{}],
salesOrderId: '',
selfBillingMode: false,
taxExemptReason: '',
taxPointDate: '',
taxSubtotals: [{category: '', country: '', percentage: '', taxAmount: '', taxableAmount: ''}],
taxSystem: '',
taxesDutiesFees: [{}],
transactionType: '',
ublExtensions: [],
vatReverseCharge: false,
x2y: ''
},
invoiceData: {conversionStrategy: '', document: ''},
invoiceRecipient: {emails: [], publicIdentifiers: [{}]},
legalEntityId: 0,
legalSupplierId: 0,
mode: '',
routing: {clearWithoutSending: false, eIdentifiers: [{id: '', scheme: ''}], emails: []},
supplierId: 0
}));
req.end();
const request = require('request');
const options = {
method: 'POST',
url: '{{baseUrl}}/invoice_submissions',
headers: {'content-type': 'application/json'},
body: {
attachments: [
{
description: '',
document: '',
documentId: '',
filename: '',
mimeType: '',
primaryImage: false
}
],
createPrimaryImage: false,
document: '',
documentUrl: '',
idempotencyGuid: '',
invoice: {
accountingCost: '',
accountingCurrencyTaxAmount: '',
accountingCurrencyTaxAmountCurrency: '',
accountingCustomerParty: {
party: {
address: {city: '', country: '', county: '', street1: '', street2: '', zip: ''},
companyName: '',
contact: {email: '', firstName: '', id: '', lastName: '', phone: ''}
},
publicIdentifiers: [{id: '', scheme: ''}]
},
accountingSupplierParty: {party: {contact: {}}},
allowanceCharges: [
{
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
baseAmountExcludingTax: '',
baseAmountIncludingTax: '',
reason: '',
reasonCode: '',
tax: {amount: '', category: '', country: '', percentage: ''},
taxesDutiesFees: [{}]
}
],
amountIncludingVat: '',
attachments: [{}],
billingReference: '',
buyerReference: '',
consumerTaxMode: false,
contractDocumentReference: '',
delivery: {
actualDate: '',
deliveryLocation: {address: {}, id: '', locationName: '', schemeAgencyId: '', schemeId: ''},
deliveryParty: {party: {}},
deliveryPartyName: '',
quantity: '',
requestedDeliveryPeriod: '',
shippingMarks: ''
},
documentCurrencyCode: '',
dueDate: '',
invoiceLines: [
{
accountingCost: '',
additionalItemProperties: [{name: '', value: ''}],
allowanceCharge: '',
allowanceCharges: [
{amountExcludingTax: '', baseAmountExcludingTax: '', reason: '', reasonCode: ''}
],
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
buyersItemIdentification: '',
description: '',
invoicePeriod: '',
itemPrice: '',
lineId: '',
name: '',
note: '',
orderLineReferenceLineId: '',
quantity: '',
quantityUnitCode: '',
references: [{documentId: '', documentType: '', issueDate: '', lineId: ''}],
sellersItemIdentification: '',
standardItemIdentification: '',
standardItemIdentificationSchemeAgencyId: '',
standardItemIdentificationSchemeId: '',
tax: {},
taxesDutiesFees: [{}]
}
],
invoiceNumber: '',
invoicePeriod: '',
invoiceType: '',
issueDate: '',
issueReasons: [],
note: '',
orderReference: '',
paymentMeansArray: [
{
account: '',
amount: '',
branche_code: '',
code: '',
holder: '',
mandate: '',
network: '',
paymentId: ''
}
],
paymentMeansBic: '',
paymentMeansCode: '',
paymentMeansIban: '',
paymentMeansPaymentId: '',
paymentTerms: {note: ''},
preferredInvoiceType: '',
prepaidAmount: '',
priceMode: '',
projectReference: '',
references: [{}],
salesOrderId: '',
selfBillingMode: false,
taxExemptReason: '',
taxPointDate: '',
taxSubtotals: [{category: '', country: '', percentage: '', taxAmount: '', taxableAmount: ''}],
taxSystem: '',
taxesDutiesFees: [{}],
transactionType: '',
ublExtensions: [],
vatReverseCharge: false,
x2y: ''
},
invoiceData: {conversionStrategy: '', document: ''},
invoiceRecipient: {emails: [], publicIdentifiers: [{}]},
legalEntityId: 0,
legalSupplierId: 0,
mode: '',
routing: {clearWithoutSending: false, eIdentifiers: [{id: '', scheme: ''}], emails: []},
supplierId: 0
},
json: true
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('POST', '{{baseUrl}}/invoice_submissions');
req.headers({
'content-type': 'application/json'
});
req.type('json');
req.send({
attachments: [
{
description: '',
document: '',
documentId: '',
filename: '',
mimeType: '',
primaryImage: false
}
],
createPrimaryImage: false,
document: '',
documentUrl: '',
idempotencyGuid: '',
invoice: {
accountingCost: '',
accountingCurrencyTaxAmount: '',
accountingCurrencyTaxAmountCurrency: '',
accountingCustomerParty: {
party: {
address: {
city: '',
country: '',
county: '',
street1: '',
street2: '',
zip: ''
},
companyName: '',
contact: {
email: '',
firstName: '',
id: '',
lastName: '',
phone: ''
}
},
publicIdentifiers: [
{
id: '',
scheme: ''
}
]
},
accountingSupplierParty: {
party: {
contact: {}
}
},
allowanceCharges: [
{
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
baseAmountExcludingTax: '',
baseAmountIncludingTax: '',
reason: '',
reasonCode: '',
tax: {
amount: '',
category: '',
country: '',
percentage: ''
},
taxesDutiesFees: [
{}
]
}
],
amountIncludingVat: '',
attachments: [
{}
],
billingReference: '',
buyerReference: '',
consumerTaxMode: false,
contractDocumentReference: '',
delivery: {
actualDate: '',
deliveryLocation: {
address: {},
id: '',
locationName: '',
schemeAgencyId: '',
schemeId: ''
},
deliveryParty: {
party: {}
},
deliveryPartyName: '',
quantity: '',
requestedDeliveryPeriod: '',
shippingMarks: ''
},
documentCurrencyCode: '',
dueDate: '',
invoiceLines: [
{
accountingCost: '',
additionalItemProperties: [
{
name: '',
value: ''
}
],
allowanceCharge: '',
allowanceCharges: [
{
amountExcludingTax: '',
baseAmountExcludingTax: '',
reason: '',
reasonCode: ''
}
],
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
buyersItemIdentification: '',
description: '',
invoicePeriod: '',
itemPrice: '',
lineId: '',
name: '',
note: '',
orderLineReferenceLineId: '',
quantity: '',
quantityUnitCode: '',
references: [
{
documentId: '',
documentType: '',
issueDate: '',
lineId: ''
}
],
sellersItemIdentification: '',
standardItemIdentification: '',
standardItemIdentificationSchemeAgencyId: '',
standardItemIdentificationSchemeId: '',
tax: {},
taxesDutiesFees: [
{}
]
}
],
invoiceNumber: '',
invoicePeriod: '',
invoiceType: '',
issueDate: '',
issueReasons: [],
note: '',
orderReference: '',
paymentMeansArray: [
{
account: '',
amount: '',
branche_code: '',
code: '',
holder: '',
mandate: '',
network: '',
paymentId: ''
}
],
paymentMeansBic: '',
paymentMeansCode: '',
paymentMeansIban: '',
paymentMeansPaymentId: '',
paymentTerms: {
note: ''
},
preferredInvoiceType: '',
prepaidAmount: '',
priceMode: '',
projectReference: '',
references: [
{}
],
salesOrderId: '',
selfBillingMode: false,
taxExemptReason: '',
taxPointDate: '',
taxSubtotals: [
{
category: '',
country: '',
percentage: '',
taxAmount: '',
taxableAmount: ''
}
],
taxSystem: '',
taxesDutiesFees: [
{}
],
transactionType: '',
ublExtensions: [],
vatReverseCharge: false,
x2y: ''
},
invoiceData: {
conversionStrategy: '',
document: ''
},
invoiceRecipient: {
emails: [],
publicIdentifiers: [
{}
]
},
legalEntityId: 0,
legalSupplierId: 0,
mode: '',
routing: {
clearWithoutSending: false,
eIdentifiers: [
{
id: '',
scheme: ''
}
],
emails: []
},
supplierId: 0
});
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'POST',
url: '{{baseUrl}}/invoice_submissions',
headers: {'content-type': 'application/json'},
data: {
attachments: [
{
description: '',
document: '',
documentId: '',
filename: '',
mimeType: '',
primaryImage: false
}
],
createPrimaryImage: false,
document: '',
documentUrl: '',
idempotencyGuid: '',
invoice: {
accountingCost: '',
accountingCurrencyTaxAmount: '',
accountingCurrencyTaxAmountCurrency: '',
accountingCustomerParty: {
party: {
address: {city: '', country: '', county: '', street1: '', street2: '', zip: ''},
companyName: '',
contact: {email: '', firstName: '', id: '', lastName: '', phone: ''}
},
publicIdentifiers: [{id: '', scheme: ''}]
},
accountingSupplierParty: {party: {contact: {}}},
allowanceCharges: [
{
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
baseAmountExcludingTax: '',
baseAmountIncludingTax: '',
reason: '',
reasonCode: '',
tax: {amount: '', category: '', country: '', percentage: ''},
taxesDutiesFees: [{}]
}
],
amountIncludingVat: '',
attachments: [{}],
billingReference: '',
buyerReference: '',
consumerTaxMode: false,
contractDocumentReference: '',
delivery: {
actualDate: '',
deliveryLocation: {address: {}, id: '', locationName: '', schemeAgencyId: '', schemeId: ''},
deliveryParty: {party: {}},
deliveryPartyName: '',
quantity: '',
requestedDeliveryPeriod: '',
shippingMarks: ''
},
documentCurrencyCode: '',
dueDate: '',
invoiceLines: [
{
accountingCost: '',
additionalItemProperties: [{name: '', value: ''}],
allowanceCharge: '',
allowanceCharges: [
{amountExcludingTax: '', baseAmountExcludingTax: '', reason: '', reasonCode: ''}
],
amountExcludingTax: '',
amountExcludingVat: '',
amountIncludingTax: '',
buyersItemIdentification: '',
description: '',
invoicePeriod: '',
itemPrice: '',
lineId: '',
name: '',
note: '',
orderLineReferenceLineId: '',
quantity: '',
quantityUnitCode: '',
references: [{documentId: '', documentType: '', issueDate: '', lineId: ''}],
sellersItemIdentification: '',
standardItemIdentification: '',
standardItemIdentificationSchemeAgencyId: '',
standardItemIdentificationSchemeId: '',
tax: {},
taxesDutiesFees: [{}]
}
],
invoiceNumber: '',
invoicePeriod: '',
invoiceType: '',
issueDate: '',
issueReasons: [],
note: '',
orderReference: '',
paymentMeansArray: [
{
account: '',
amount: '',
branche_code: '',
code: '',
holder: '',
mandate: '',
network: '',
paymentId: ''
}
],
paymentMeansBic: '',
paymentMeansCode: '',
paymentMeansIban: '',
paymentMeansPaymentId: '',
paymentTerms: {note: ''},
preferredInvoiceType: '',
prepaidAmount: '',
priceMode: '',
projectReference: '',
references: [{}],
salesOrderId: '',
selfBillingMode: false,
taxExemptReason: '',
taxPointDate: '',
taxSubtotals: [{category: '', country: '', percentage: '', taxAmount: '', taxableAmount: ''}],
taxSystem: '',
taxesDutiesFees: [{}],
transactionType: '',
ublExtensions: [],
vatReverseCharge: false,
x2y: ''
},
invoiceData: {conversionStrategy: '', document: ''},
invoiceRecipient: {emails: [], publicIdentifiers: [{}]},
legalEntityId: 0,
legalSupplierId: 0,
mode: '',
routing: {clearWithoutSending: false, eIdentifiers: [{id: '', scheme: ''}], emails: []},
supplierId: 0
}
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/invoice_submissions';
const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: '{"attachments":[{"description":"","document":"","documentId":"","filename":"","mimeType":"","primaryImage":false}],"createPrimaryImage":false,"document":"","documentUrl":"","idempotencyGuid":"","invoice":{"accountingCost":"","accountingCurrencyTaxAmount":"","accountingCurrencyTaxAmountCurrency":"","accountingCustomerParty":{"party":{"address":{"city":"","country":"","county":"","street1":"","street2":"","zip":""},"companyName":"","contact":{"email":"","firstName":"","id":"","lastName":"","phone":""}},"publicIdentifiers":[{"id":"","scheme":""}]},"accountingSupplierParty":{"party":{"contact":{}}},"allowanceCharges":[{"amountExcludingTax":"","amountExcludingVat":"","amountIncludingTax":"","baseAmountExcludingTax":"","baseAmountIncludingTax":"","reason":"","reasonCode":"","tax":{"amount":"","category":"","country":"","percentage":""},"taxesDutiesFees":[{}]}],"amountIncludingVat":"","attachments":[{}],"billingReference":"","buyerReference":"","consumerTaxMode":false,"contractDocumentReference":"","delivery":{"actualDate":"","deliveryLocation":{"address":{},"id":"","locationName":"","schemeAgencyId":"","schemeId":""},"deliveryParty":{"party":{}},"deliveryPartyName":"","quantity":"","requestedDeliveryPeriod":"","shippingMarks":""},"documentCurrencyCode":"","dueDate":"","invoiceLines":[{"accountingCost":"","additionalItemProperties":[{"name":"","value":""}],"allowanceCharge":"","allowanceCharges":[{"amountExcludingTax":"","baseAmountExcludingTax":"","reason":"","reasonCode":""}],"amountExcludingTax":"","amountExcludingVat":"","amountIncludingTax":"","buyersItemIdentification":"","description":"","invoicePeriod":"","itemPrice":"","lineId":"","name":"","note":"","orderLineReferenceLineId":"","quantity":"","quantityUnitCode":"","references":[{"documentId":"","documentType":"","issueDate":"","lineId":""}],"sellersItemIdentification":"","standardItemIdentification":"","standardItemIdentificationSchemeAgencyId":"","standardItemIdentificationSchemeId":"","tax":{},"taxesDutiesFees":[{}]}],"invoiceNumber":"","invoicePeriod":"","invoiceType":"","issueDate":"","issueReasons":[],"note":"","orderReference":"","paymentMeansArray":[{"account":"","amount":"","branche_code":"","code":"","holder":"","mandate":"","network":"","paymentId":""}],"paymentMeansBic":"","paymentMeansCode":"","paymentMeansIban":"","paymentMeansPaymentId":"","paymentTerms":{"note":""},"preferredInvoiceType":"","prepaidAmount":"","priceMode":"","projectReference":"","references":[{}],"salesOrderId":"","selfBillingMode":false,"taxExemptReason":"","taxPointDate":"","taxSubtotals":[{"category":"","country":"","percentage":"","taxAmount":"","taxableAmount":""}],"taxSystem":"","taxesDutiesFees":[{}],"transactionType":"","ublExtensions":[],"vatReverseCharge":false,"x2y":""},"invoiceData":{"conversionStrategy":"","document":""},"invoiceRecipient":{"emails":[],"publicIdentifiers":[{}]},"legalEntityId":0,"legalSupplierId":0,"mode":"","routing":{"clearWithoutSending":false,"eIdentifiers":[{"id":"","scheme":""}],"emails":[]},"supplierId":0}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"attachments": @[ @{ @"description": @"", @"document": @"", @"documentId": @"", @"filename": @"", @"mimeType": @"", @"primaryImage": @NO } ],
@"createPrimaryImage": @NO,
@"document": @"",
@"documentUrl": @"",
@"idempotencyGuid": @"",
@"invoice": @{ @"accountingCost": @"", @"accountingCurrencyTaxAmount": @"", @"accountingCurrencyTaxAmountCurrency": @"", @"accountingCustomerParty": @{ @"party": @{ @"address": @{ @"city": @"", @"country": @"", @"county": @"", @"street1": @"", @"street2": @"", @"zip": @"" }, @"companyName": @"", @"contact": @{ @"email": @"", @"firstName": @"", @"id": @"", @"lastName": @"", @"phone": @"" } }, @"publicIdentifiers": @[ @{ @"id": @"", @"scheme": @"" } ] }, @"accountingSupplierParty": @{ @"party": @{ @"contact": @{ } } }, @"allowanceCharges": @[ @{ @"amountExcludingTax": @"", @"amountExcludingVat": @"", @"amountIncludingTax": @"", @"baseAmountExcludingTax": @"", @"baseAmountIncludingTax": @"", @"reason": @"", @"reasonCode": @"", @"tax": @{ @"amount": @"", @"category": @"", @"country": @"", @"percentage": @"" }, @"taxesDutiesFees": @[ @{ } ] } ], @"amountIncludingVat": @"", @"attachments": @[ @{ } ], @"billingReference": @"", @"buyerReference": @"", @"consumerTaxMode": @NO, @"contractDocumentReference": @"", @"delivery": @{ @"actualDate": @"", @"deliveryLocation": @{ @"address": @{ }, @"id": @"", @"locationName": @"", @"schemeAgencyId": @"", @"schemeId": @"" }, @"deliveryParty": @{ @"party": @{ } }, @"deliveryPartyName": @"", @"quantity": @"", @"requestedDeliveryPeriod": @"", @"shippingMarks": @"" }, @"documentCurrencyCode": @"", @"dueDate": @"", @"invoiceLines": @[ @{ @"accountingCost": @"", @"additionalItemProperties": @[ @{ @"name": @"", @"value": @"" } ], @"allowanceCharge": @"", @"allowanceCharges": @[ @{ @"amountExcludingTax": @"", @"baseAmountExcludingTax": @"", @"reason": @"", @"reasonCode": @"" } ], @"amountExcludingTax": @"", @"amountExcludingVat": @"", @"amountIncludingTax": @"", @"buyersItemIdentification": @"", @"description": @"", @"invoicePeriod": @"", @"itemPrice": @"", @"lineId": @"", @"name": @"", @"note": @"", @"orderLineReferenceLineId": @"", @"quantity": @"", @"quantityUnitCode": @"", @"references": @[ @{ @"documentId": @"", @"documentType": @"", @"issueDate": @"", @"lineId": @"" } ], @"sellersItemIdentification": @"", @"standardItemIdentification": @"", @"standardItemIdentificationSchemeAgencyId": @"", @"standardItemIdentificationSchemeId": @"", @"tax": @{ }, @"taxesDutiesFees": @[ @{ } ] } ], @"invoiceNumber": @"", @"invoicePeriod": @"", @"invoiceType": @"", @"issueDate": @"", @"issueReasons": @[ ], @"note": @"", @"orderReference": @"", @"paymentMeansArray": @[ @{ @"account": @"", @"amount": @"", @"branche_code": @"", @"code": @"", @"holder": @"", @"mandate": @"", @"network": @"", @"paymentId": @"" } ], @"paymentMeansBic": @"", @"paymentMeansCode": @"", @"paymentMeansIban": @"", @"paymentMeansPaymentId": @"", @"paymentTerms": @{ @"note": @"" }, @"preferredInvoiceType": @"", @"prepaidAmount": @"", @"priceMode": @"", @"projectReference": @"", @"references": @[ @{ } ], @"salesOrderId": @"", @"selfBillingMode": @NO, @"taxExemptReason": @"", @"taxPointDate": @"", @"taxSubtotals": @[ @{ @"category": @"", @"country": @"", @"percentage": @"", @"taxAmount": @"", @"taxableAmount": @"" } ], @"taxSystem": @"", @"taxesDutiesFees": @[ @{ } ], @"transactionType": @"", @"ublExtensions": @[ ], @"vatReverseCharge": @NO, @"x2y": @"" },
@"invoiceData": @{ @"conversionStrategy": @"", @"document": @"" },
@"invoiceRecipient": @{ @"emails": @[ ], @"publicIdentifiers": @[ @{ } ] },
@"legalEntityId": @0,
@"legalSupplierId": @0,
@"mode": @"",
@"routing": @{ @"clearWithoutSending": @NO, @"eIdentifiers": @[ @{ @"id": @"", @"scheme": @"" } ], @"emails": @[ ] },
@"supplierId": @0 };
NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/invoice_submissions"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/invoice_submissions" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}" in
Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/invoice_submissions",
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([
'attachments' => [
[
'description' => '',
'document' => '',
'documentId' => '',
'filename' => '',
'mimeType' => '',
'primaryImage' => null
]
],
'createPrimaryImage' => null,
'document' => '',
'documentUrl' => '',
'idempotencyGuid' => '',
'invoice' => [
'accountingCost' => '',
'accountingCurrencyTaxAmount' => '',
'accountingCurrencyTaxAmountCurrency' => '',
'accountingCustomerParty' => [
'party' => [
'address' => [
'city' => '',
'country' => '',
'county' => '',
'street1' => '',
'street2' => '',
'zip' => ''
],
'companyName' => '',
'contact' => [
'email' => '',
'firstName' => '',
'id' => '',
'lastName' => '',
'phone' => ''
]
],
'publicIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
]
],
'accountingSupplierParty' => [
'party' => [
'contact' => [
]
]
],
'allowanceCharges' => [
[
'amountExcludingTax' => '',
'amountExcludingVat' => '',
'amountIncludingTax' => '',
'baseAmountExcludingTax' => '',
'baseAmountIncludingTax' => '',
'reason' => '',
'reasonCode' => '',
'tax' => [
'amount' => '',
'category' => '',
'country' => '',
'percentage' => ''
],
'taxesDutiesFees' => [
[
]
]
]
],
'amountIncludingVat' => '',
'attachments' => [
[
]
],
'billingReference' => '',
'buyerReference' => '',
'consumerTaxMode' => null,
'contractDocumentReference' => '',
'delivery' => [
'actualDate' => '',
'deliveryLocation' => [
'address' => [
],
'id' => '',
'locationName' => '',
'schemeAgencyId' => '',
'schemeId' => ''
],
'deliveryParty' => [
'party' => [
]
],
'deliveryPartyName' => '',
'quantity' => '',
'requestedDeliveryPeriod' => '',
'shippingMarks' => ''
],
'documentCurrencyCode' => '',
'dueDate' => '',
'invoiceLines' => [
[
'accountingCost' => '',
'additionalItemProperties' => [
[
'name' => '',
'value' => ''
]
],
'allowanceCharge' => '',
'allowanceCharges' => [
[
'amountExcludingTax' => '',
'baseAmountExcludingTax' => '',
'reason' => '',
'reasonCode' => ''
]
],
'amountExcludingTax' => '',
'amountExcludingVat' => '',
'amountIncludingTax' => '',
'buyersItemIdentification' => '',
'description' => '',
'invoicePeriod' => '',
'itemPrice' => '',
'lineId' => '',
'name' => '',
'note' => '',
'orderLineReferenceLineId' => '',
'quantity' => '',
'quantityUnitCode' => '',
'references' => [
[
'documentId' => '',
'documentType' => '',
'issueDate' => '',
'lineId' => ''
]
],
'sellersItemIdentification' => '',
'standardItemIdentification' => '',
'standardItemIdentificationSchemeAgencyId' => '',
'standardItemIdentificationSchemeId' => '',
'tax' => [
],
'taxesDutiesFees' => [
[
]
]
]
],
'invoiceNumber' => '',
'invoicePeriod' => '',
'invoiceType' => '',
'issueDate' => '',
'issueReasons' => [
],
'note' => '',
'orderReference' => '',
'paymentMeansArray' => [
[
'account' => '',
'amount' => '',
'branche_code' => '',
'code' => '',
'holder' => '',
'mandate' => '',
'network' => '',
'paymentId' => ''
]
],
'paymentMeansBic' => '',
'paymentMeansCode' => '',
'paymentMeansIban' => '',
'paymentMeansPaymentId' => '',
'paymentTerms' => [
'note' => ''
],
'preferredInvoiceType' => '',
'prepaidAmount' => '',
'priceMode' => '',
'projectReference' => '',
'references' => [
[
]
],
'salesOrderId' => '',
'selfBillingMode' => null,
'taxExemptReason' => '',
'taxPointDate' => '',
'taxSubtotals' => [
[
'category' => '',
'country' => '',
'percentage' => '',
'taxAmount' => '',
'taxableAmount' => ''
]
],
'taxSystem' => '',
'taxesDutiesFees' => [
[
]
],
'transactionType' => '',
'ublExtensions' => [
],
'vatReverseCharge' => null,
'x2y' => ''
],
'invoiceData' => [
'conversionStrategy' => '',
'document' => ''
],
'invoiceRecipient' => [
'emails' => [
],
'publicIdentifiers' => [
[
]
]
],
'legalEntityId' => 0,
'legalSupplierId' => 0,
'mode' => '',
'routing' => [
'clearWithoutSending' => null,
'eIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
],
'emails' => [
]
],
'supplierId' => 0
]),
CURLOPT_HTTPHEADER => [
"content-type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('POST', '{{baseUrl}}/invoice_submissions', [
'body' => '{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": "",
"documentUrl": "",
"idempotencyGuid": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceData": {
"conversionStrategy": "",
"document": ""
},
"invoiceRecipient": {
"emails": [],
"publicIdentifiers": [
{}
]
},
"legalEntityId": 0,
"legalSupplierId": 0,
"mode": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
},
"supplierId": 0
}',
'headers' => [
'content-type' => 'application/json',
],
]);
echo $response->getBody();
setUrl('{{baseUrl}}/invoice_submissions');
$request->setMethod(HTTP_METH_POST);
$request->setHeaders([
'content-type' => 'application/json'
]);
$request->setContentType('application/json');
$request->setBody(json_encode([
'attachments' => [
[
'description' => '',
'document' => '',
'documentId' => '',
'filename' => '',
'mimeType' => '',
'primaryImage' => null
]
],
'createPrimaryImage' => null,
'document' => '',
'documentUrl' => '',
'idempotencyGuid' => '',
'invoice' => [
'accountingCost' => '',
'accountingCurrencyTaxAmount' => '',
'accountingCurrencyTaxAmountCurrency' => '',
'accountingCustomerParty' => [
'party' => [
'address' => [
'city' => '',
'country' => '',
'county' => '',
'street1' => '',
'street2' => '',
'zip' => ''
],
'companyName' => '',
'contact' => [
'email' => '',
'firstName' => '',
'id' => '',
'lastName' => '',
'phone' => ''
]
],
'publicIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
]
],
'accountingSupplierParty' => [
'party' => [
'contact' => [
]
]
],
'allowanceCharges' => [
[
'amountExcludingTax' => '',
'amountExcludingVat' => '',
'amountIncludingTax' => '',
'baseAmountExcludingTax' => '',
'baseAmountIncludingTax' => '',
'reason' => '',
'reasonCode' => '',
'tax' => [
'amount' => '',
'category' => '',
'country' => '',
'percentage' => ''
],
'taxesDutiesFees' => [
[
]
]
]
],
'amountIncludingVat' => '',
'attachments' => [
[
]
],
'billingReference' => '',
'buyerReference' => '',
'consumerTaxMode' => null,
'contractDocumentReference' => '',
'delivery' => [
'actualDate' => '',
'deliveryLocation' => [
'address' => [
],
'id' => '',
'locationName' => '',
'schemeAgencyId' => '',
'schemeId' => ''
],
'deliveryParty' => [
'party' => [
]
],
'deliveryPartyName' => '',
'quantity' => '',
'requestedDeliveryPeriod' => '',
'shippingMarks' => ''
],
'documentCurrencyCode' => '',
'dueDate' => '',
'invoiceLines' => [
[
'accountingCost' => '',
'additionalItemProperties' => [
[
'name' => '',
'value' => ''
]
],
'allowanceCharge' => '',
'allowanceCharges' => [
[
'amountExcludingTax' => '',
'baseAmountExcludingTax' => '',
'reason' => '',
'reasonCode' => ''
]
],
'amountExcludingTax' => '',
'amountExcludingVat' => '',
'amountIncludingTax' => '',
'buyersItemIdentification' => '',
'description' => '',
'invoicePeriod' => '',
'itemPrice' => '',
'lineId' => '',
'name' => '',
'note' => '',
'orderLineReferenceLineId' => '',
'quantity' => '',
'quantityUnitCode' => '',
'references' => [
[
'documentId' => '',
'documentType' => '',
'issueDate' => '',
'lineId' => ''
]
],
'sellersItemIdentification' => '',
'standardItemIdentification' => '',
'standardItemIdentificationSchemeAgencyId' => '',
'standardItemIdentificationSchemeId' => '',
'tax' => [
],
'taxesDutiesFees' => [
[
]
]
]
],
'invoiceNumber' => '',
'invoicePeriod' => '',
'invoiceType' => '',
'issueDate' => '',
'issueReasons' => [
],
'note' => '',
'orderReference' => '',
'paymentMeansArray' => [
[
'account' => '',
'amount' => '',
'branche_code' => '',
'code' => '',
'holder' => '',
'mandate' => '',
'network' => '',
'paymentId' => ''
]
],
'paymentMeansBic' => '',
'paymentMeansCode' => '',
'paymentMeansIban' => '',
'paymentMeansPaymentId' => '',
'paymentTerms' => [
'note' => ''
],
'preferredInvoiceType' => '',
'prepaidAmount' => '',
'priceMode' => '',
'projectReference' => '',
'references' => [
[
]
],
'salesOrderId' => '',
'selfBillingMode' => null,
'taxExemptReason' => '',
'taxPointDate' => '',
'taxSubtotals' => [
[
'category' => '',
'country' => '',
'percentage' => '',
'taxAmount' => '',
'taxableAmount' => ''
]
],
'taxSystem' => '',
'taxesDutiesFees' => [
[
]
],
'transactionType' => '',
'ublExtensions' => [
],
'vatReverseCharge' => null,
'x2y' => ''
],
'invoiceData' => [
'conversionStrategy' => '',
'document' => ''
],
'invoiceRecipient' => [
'emails' => [
],
'publicIdentifiers' => [
[
]
]
],
'legalEntityId' => 0,
'legalSupplierId' => 0,
'mode' => '',
'routing' => [
'clearWithoutSending' => null,
'eIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
],
'emails' => [
]
],
'supplierId' => 0
]));
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
append(json_encode([
'attachments' => [
[
'description' => '',
'document' => '',
'documentId' => '',
'filename' => '',
'mimeType' => '',
'primaryImage' => null
]
],
'createPrimaryImage' => null,
'document' => '',
'documentUrl' => '',
'idempotencyGuid' => '',
'invoice' => [
'accountingCost' => '',
'accountingCurrencyTaxAmount' => '',
'accountingCurrencyTaxAmountCurrency' => '',
'accountingCustomerParty' => [
'party' => [
'address' => [
'city' => '',
'country' => '',
'county' => '',
'street1' => '',
'street2' => '',
'zip' => ''
],
'companyName' => '',
'contact' => [
'email' => '',
'firstName' => '',
'id' => '',
'lastName' => '',
'phone' => ''
]
],
'publicIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
]
],
'accountingSupplierParty' => [
'party' => [
'contact' => [
]
]
],
'allowanceCharges' => [
[
'amountExcludingTax' => '',
'amountExcludingVat' => '',
'amountIncludingTax' => '',
'baseAmountExcludingTax' => '',
'baseAmountIncludingTax' => '',
'reason' => '',
'reasonCode' => '',
'tax' => [
'amount' => '',
'category' => '',
'country' => '',
'percentage' => ''
],
'taxesDutiesFees' => [
[
]
]
]
],
'amountIncludingVat' => '',
'attachments' => [
[
]
],
'billingReference' => '',
'buyerReference' => '',
'consumerTaxMode' => null,
'contractDocumentReference' => '',
'delivery' => [
'actualDate' => '',
'deliveryLocation' => [
'address' => [
],
'id' => '',
'locationName' => '',
'schemeAgencyId' => '',
'schemeId' => ''
],
'deliveryParty' => [
'party' => [
]
],
'deliveryPartyName' => '',
'quantity' => '',
'requestedDeliveryPeriod' => '',
'shippingMarks' => ''
],
'documentCurrencyCode' => '',
'dueDate' => '',
'invoiceLines' => [
[
'accountingCost' => '',
'additionalItemProperties' => [
[
'name' => '',
'value' => ''
]
],
'allowanceCharge' => '',
'allowanceCharges' => [
[
'amountExcludingTax' => '',
'baseAmountExcludingTax' => '',
'reason' => '',
'reasonCode' => ''
]
],
'amountExcludingTax' => '',
'amountExcludingVat' => '',
'amountIncludingTax' => '',
'buyersItemIdentification' => '',
'description' => '',
'invoicePeriod' => '',
'itemPrice' => '',
'lineId' => '',
'name' => '',
'note' => '',
'orderLineReferenceLineId' => '',
'quantity' => '',
'quantityUnitCode' => '',
'references' => [
[
'documentId' => '',
'documentType' => '',
'issueDate' => '',
'lineId' => ''
]
],
'sellersItemIdentification' => '',
'standardItemIdentification' => '',
'standardItemIdentificationSchemeAgencyId' => '',
'standardItemIdentificationSchemeId' => '',
'tax' => [
],
'taxesDutiesFees' => [
[
]
]
]
],
'invoiceNumber' => '',
'invoicePeriod' => '',
'invoiceType' => '',
'issueDate' => '',
'issueReasons' => [
],
'note' => '',
'orderReference' => '',
'paymentMeansArray' => [
[
'account' => '',
'amount' => '',
'branche_code' => '',
'code' => '',
'holder' => '',
'mandate' => '',
'network' => '',
'paymentId' => ''
]
],
'paymentMeansBic' => '',
'paymentMeansCode' => '',
'paymentMeansIban' => '',
'paymentMeansPaymentId' => '',
'paymentTerms' => [
'note' => ''
],
'preferredInvoiceType' => '',
'prepaidAmount' => '',
'priceMode' => '',
'projectReference' => '',
'references' => [
[
]
],
'salesOrderId' => '',
'selfBillingMode' => null,
'taxExemptReason' => '',
'taxPointDate' => '',
'taxSubtotals' => [
[
'category' => '',
'country' => '',
'percentage' => '',
'taxAmount' => '',
'taxableAmount' => ''
]
],
'taxSystem' => '',
'taxesDutiesFees' => [
[
]
],
'transactionType' => '',
'ublExtensions' => [
],
'vatReverseCharge' => null,
'x2y' => ''
],
'invoiceData' => [
'conversionStrategy' => '',
'document' => ''
],
'invoiceRecipient' => [
'emails' => [
],
'publicIdentifiers' => [
[
]
]
],
'legalEntityId' => 0,
'legalSupplierId' => 0,
'mode' => '',
'routing' => [
'clearWithoutSending' => null,
'eIdentifiers' => [
[
'id' => '',
'scheme' => ''
]
],
'emails' => [
]
],
'supplierId' => 0
]));
$request->setRequestUrl('{{baseUrl}}/invoice_submissions');
$request->setRequestMethod('POST');
$request->setBody($body);
$request->setHeaders([
'content-type' => 'application/json'
]);
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/invoice_submissions' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": "",
"documentUrl": "",
"idempotencyGuid": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceData": {
"conversionStrategy": "",
"document": ""
},
"invoiceRecipient": {
"emails": [],
"publicIdentifiers": [
{}
]
},
"legalEntityId": 0,
"legalSupplierId": 0,
"mode": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
},
"supplierId": 0
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/invoice_submissions' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": "",
"documentUrl": "",
"idempotencyGuid": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceData": {
"conversionStrategy": "",
"document": ""
},
"invoiceRecipient": {
"emails": [],
"publicIdentifiers": [
{}
]
},
"legalEntityId": 0,
"legalSupplierId": 0,
"mode": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
},
"supplierId": 0
}'
import http.client
conn = http.client.HTTPSConnection("example.com")
payload = "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}"
headers = { 'content-type': "application/json" }
conn.request("POST", "/baseUrl/invoice_submissions", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/invoice_submissions"
payload = {
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": False
}
],
"createPrimaryImage": False,
"document": "",
"documentUrl": "",
"idempotencyGuid": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": { "party": { "contact": {} } },
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [{}]
}
],
"amountIncludingVat": "",
"attachments": [{}],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": False,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": { "party": {} },
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [{}]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": { "note": "" },
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [{}],
"salesOrderId": "",
"selfBillingMode": False,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [{}],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": False,
"x2y": ""
},
"invoiceData": {
"conversionStrategy": "",
"document": ""
},
"invoiceRecipient": {
"emails": [],
"publicIdentifiers": [{}]
},
"legalEntityId": 0,
"legalSupplierId": 0,
"mode": "",
"routing": {
"clearWithoutSending": False,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
},
"supplierId": 0
}
headers = {"content-type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.json())
library(httr)
url <- "{{baseUrl}}/invoice_submissions"
payload <- "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}"
encode <- "json"
response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/invoice_submissions")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}"
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
headers: {'Content-Type' => 'application/json'}
)
response = conn.post('/baseUrl/invoice_submissions') do |req|
req.body = "{\n \"attachments\": [\n {\n \"description\": \"\",\n \"document\": \"\",\n \"documentId\": \"\",\n \"filename\": \"\",\n \"mimeType\": \"\",\n \"primaryImage\": false\n }\n ],\n \"createPrimaryImage\": false,\n \"document\": \"\",\n \"documentUrl\": \"\",\n \"idempotencyGuid\": \"\",\n \"invoice\": {\n \"accountingCost\": \"\",\n \"accountingCurrencyTaxAmount\": \"\",\n \"accountingCurrencyTaxAmountCurrency\": \"\",\n \"accountingCustomerParty\": {\n \"party\": {\n \"address\": {\n \"city\": \"\",\n \"country\": \"\",\n \"county\": \"\",\n \"street1\": \"\",\n \"street2\": \"\",\n \"zip\": \"\"\n },\n \"companyName\": \"\",\n \"contact\": {\n \"email\": \"\",\n \"firstName\": \"\",\n \"id\": \"\",\n \"lastName\": \"\",\n \"phone\": \"\"\n }\n },\n \"publicIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ]\n },\n \"accountingSupplierParty\": {\n \"party\": {\n \"contact\": {}\n }\n },\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"baseAmountIncludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\",\n \"tax\": {\n \"amount\": \"\",\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\"\n },\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"amountIncludingVat\": \"\",\n \"attachments\": [\n {}\n ],\n \"billingReference\": \"\",\n \"buyerReference\": \"\",\n \"consumerTaxMode\": false,\n \"contractDocumentReference\": \"\",\n \"delivery\": {\n \"actualDate\": \"\",\n \"deliveryLocation\": {\n \"address\": {},\n \"id\": \"\",\n \"locationName\": \"\",\n \"schemeAgencyId\": \"\",\n \"schemeId\": \"\"\n },\n \"deliveryParty\": {\n \"party\": {}\n },\n \"deliveryPartyName\": \"\",\n \"quantity\": \"\",\n \"requestedDeliveryPeriod\": \"\",\n \"shippingMarks\": \"\"\n },\n \"documentCurrencyCode\": \"\",\n \"dueDate\": \"\",\n \"invoiceLines\": [\n {\n \"accountingCost\": \"\",\n \"additionalItemProperties\": [\n {\n \"name\": \"\",\n \"value\": \"\"\n }\n ],\n \"allowanceCharge\": \"\",\n \"allowanceCharges\": [\n {\n \"amountExcludingTax\": \"\",\n \"baseAmountExcludingTax\": \"\",\n \"reason\": \"\",\n \"reasonCode\": \"\"\n }\n ],\n \"amountExcludingTax\": \"\",\n \"amountExcludingVat\": \"\",\n \"amountIncludingTax\": \"\",\n \"buyersItemIdentification\": \"\",\n \"description\": \"\",\n \"invoicePeriod\": \"\",\n \"itemPrice\": \"\",\n \"lineId\": \"\",\n \"name\": \"\",\n \"note\": \"\",\n \"orderLineReferenceLineId\": \"\",\n \"quantity\": \"\",\n \"quantityUnitCode\": \"\",\n \"references\": [\n {\n \"documentId\": \"\",\n \"documentType\": \"\",\n \"issueDate\": \"\",\n \"lineId\": \"\"\n }\n ],\n \"sellersItemIdentification\": \"\",\n \"standardItemIdentification\": \"\",\n \"standardItemIdentificationSchemeAgencyId\": \"\",\n \"standardItemIdentificationSchemeId\": \"\",\n \"tax\": {},\n \"taxesDutiesFees\": [\n {}\n ]\n }\n ],\n \"invoiceNumber\": \"\",\n \"invoicePeriod\": \"\",\n \"invoiceType\": \"\",\n \"issueDate\": \"\",\n \"issueReasons\": [],\n \"note\": \"\",\n \"orderReference\": \"\",\n \"paymentMeansArray\": [\n {\n \"account\": \"\",\n \"amount\": \"\",\n \"branche_code\": \"\",\n \"code\": \"\",\n \"holder\": \"\",\n \"mandate\": \"\",\n \"network\": \"\",\n \"paymentId\": \"\"\n }\n ],\n \"paymentMeansBic\": \"\",\n \"paymentMeansCode\": \"\",\n \"paymentMeansIban\": \"\",\n \"paymentMeansPaymentId\": \"\",\n \"paymentTerms\": {\n \"note\": \"\"\n },\n \"preferredInvoiceType\": \"\",\n \"prepaidAmount\": \"\",\n \"priceMode\": \"\",\n \"projectReference\": \"\",\n \"references\": [\n {}\n ],\n \"salesOrderId\": \"\",\n \"selfBillingMode\": false,\n \"taxExemptReason\": \"\",\n \"taxPointDate\": \"\",\n \"taxSubtotals\": [\n {\n \"category\": \"\",\n \"country\": \"\",\n \"percentage\": \"\",\n \"taxAmount\": \"\",\n \"taxableAmount\": \"\"\n }\n ],\n \"taxSystem\": \"\",\n \"taxesDutiesFees\": [\n {}\n ],\n \"transactionType\": \"\",\n \"ublExtensions\": [],\n \"vatReverseCharge\": false,\n \"x2y\": \"\"\n },\n \"invoiceData\": {\n \"conversionStrategy\": \"\",\n \"document\": \"\"\n },\n \"invoiceRecipient\": {\n \"emails\": [],\n \"publicIdentifiers\": [\n {}\n ]\n },\n \"legalEntityId\": 0,\n \"legalSupplierId\": 0,\n \"mode\": \"\",\n \"routing\": {\n \"clearWithoutSending\": false,\n \"eIdentifiers\": [\n {\n \"id\": \"\",\n \"scheme\": \"\"\n }\n ],\n \"emails\": []\n },\n \"supplierId\": 0\n}"
end
puts response.status
puts response.body
use serde_json::json;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/invoice_submissions";
let payload = json!({
"attachments": (
json!({
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
})
),
"createPrimaryImage": false,
"document": "",
"documentUrl": "",
"idempotencyGuid": "",
"invoice": json!({
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": json!({
"party": json!({
"address": json!({
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
}),
"companyName": "",
"contact": json!({
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
})
}),
"publicIdentifiers": (
json!({
"id": "",
"scheme": ""
})
)
}),
"accountingSupplierParty": json!({"party": json!({"contact": json!({})})}),
"allowanceCharges": (
json!({
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": json!({
"amount": "",
"category": "",
"country": "",
"percentage": ""
}),
"taxesDutiesFees": (json!({}))
})
),
"amountIncludingVat": "",
"attachments": (json!({})),
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": json!({
"actualDate": "",
"deliveryLocation": json!({
"address": json!({}),
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
}),
"deliveryParty": json!({"party": json!({})}),
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
}),
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": (
json!({
"accountingCost": "",
"additionalItemProperties": (
json!({
"name": "",
"value": ""
})
),
"allowanceCharge": "",
"allowanceCharges": (
json!({
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
})
),
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": (
json!({
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
})
),
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": json!({}),
"taxesDutiesFees": (json!({}))
})
),
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": (),
"note": "",
"orderReference": "",
"paymentMeansArray": (
json!({
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
})
),
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": json!({"note": ""}),
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": (json!({})),
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": (
json!({
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
})
),
"taxSystem": "",
"taxesDutiesFees": (json!({})),
"transactionType": "",
"ublExtensions": (),
"vatReverseCharge": false,
"x2y": ""
}),
"invoiceData": json!({
"conversionStrategy": "",
"document": ""
}),
"invoiceRecipient": json!({
"emails": (),
"publicIdentifiers": (json!({}))
}),
"legalEntityId": 0,
"legalSupplierId": 0,
"mode": "",
"routing": json!({
"clearWithoutSending": false,
"eIdentifiers": (
json!({
"id": "",
"scheme": ""
})
),
"emails": ()
}),
"supplierId": 0
});
let mut headers = reqwest::header::HeaderMap::new();
headers.insert("content-type", "application/json".parse().unwrap());
let client = reqwest::Client::new();
let response = client.post(url)
.headers(headers)
.json(&payload)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request POST \
--url {{baseUrl}}/invoice_submissions \
--header 'content-type: application/json' \
--data '{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": "",
"documentUrl": "",
"idempotencyGuid": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceData": {
"conversionStrategy": "",
"document": ""
},
"invoiceRecipient": {
"emails": [],
"publicIdentifiers": [
{}
]
},
"legalEntityId": 0,
"legalSupplierId": 0,
"mode": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
},
"supplierId": 0
}'
echo '{
"attachments": [
{
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
}
],
"createPrimaryImage": false,
"document": "",
"documentUrl": "",
"idempotencyGuid": "",
"invoice": {
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": {
"party": {
"address": {
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
},
"companyName": "",
"contact": {
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
}
},
"publicIdentifiers": [
{
"id": "",
"scheme": ""
}
]
},
"accountingSupplierParty": {
"party": {
"contact": {}
}
},
"allowanceCharges": [
{
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": {
"amount": "",
"category": "",
"country": "",
"percentage": ""
},
"taxesDutiesFees": [
{}
]
}
],
"amountIncludingVat": "",
"attachments": [
{}
],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": {
"actualDate": "",
"deliveryLocation": {
"address": {},
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
},
"deliveryParty": {
"party": {}
},
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
},
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
{
"accountingCost": "",
"additionalItemProperties": [
{
"name": "",
"value": ""
}
],
"allowanceCharge": "",
"allowanceCharges": [
{
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
}
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
{
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
}
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": {},
"taxesDutiesFees": [
{}
]
}
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
{
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
}
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": {
"note": ""
},
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [
{}
],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
{
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
}
],
"taxSystem": "",
"taxesDutiesFees": [
{}
],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
},
"invoiceData": {
"conversionStrategy": "",
"document": ""
},
"invoiceRecipient": {
"emails": [],
"publicIdentifiers": [
{}
]
},
"legalEntityId": 0,
"legalSupplierId": 0,
"mode": "",
"routing": {
"clearWithoutSending": false,
"eIdentifiers": [
{
"id": "",
"scheme": ""
}
],
"emails": []
},
"supplierId": 0
}' | \
http POST {{baseUrl}}/invoice_submissions \
content-type:application/json
wget --quiet \
--method POST \
--header 'content-type: application/json' \
--body-data '{\n "attachments": [\n {\n "description": "",\n "document": "",\n "documentId": "",\n "filename": "",\n "mimeType": "",\n "primaryImage": false\n }\n ],\n "createPrimaryImage": false,\n "document": "",\n "documentUrl": "",\n "idempotencyGuid": "",\n "invoice": {\n "accountingCost": "",\n "accountingCurrencyTaxAmount": "",\n "accountingCurrencyTaxAmountCurrency": "",\n "accountingCustomerParty": {\n "party": {\n "address": {\n "city": "",\n "country": "",\n "county": "",\n "street1": "",\n "street2": "",\n "zip": ""\n },\n "companyName": "",\n "contact": {\n "email": "",\n "firstName": "",\n "id": "",\n "lastName": "",\n "phone": ""\n }\n },\n "publicIdentifiers": [\n {\n "id": "",\n "scheme": ""\n }\n ]\n },\n "accountingSupplierParty": {\n "party": {\n "contact": {}\n }\n },\n "allowanceCharges": [\n {\n "amountExcludingTax": "",\n "amountExcludingVat": "",\n "amountIncludingTax": "",\n "baseAmountExcludingTax": "",\n "baseAmountIncludingTax": "",\n "reason": "",\n "reasonCode": "",\n "tax": {\n "amount": "",\n "category": "",\n "country": "",\n "percentage": ""\n },\n "taxesDutiesFees": [\n {}\n ]\n }\n ],\n "amountIncludingVat": "",\n "attachments": [\n {}\n ],\n "billingReference": "",\n "buyerReference": "",\n "consumerTaxMode": false,\n "contractDocumentReference": "",\n "delivery": {\n "actualDate": "",\n "deliveryLocation": {\n "address": {},\n "id": "",\n "locationName": "",\n "schemeAgencyId": "",\n "schemeId": ""\n },\n "deliveryParty": {\n "party": {}\n },\n "deliveryPartyName": "",\n "quantity": "",\n "requestedDeliveryPeriod": "",\n "shippingMarks": ""\n },\n "documentCurrencyCode": "",\n "dueDate": "",\n "invoiceLines": [\n {\n "accountingCost": "",\n "additionalItemProperties": [\n {\n "name": "",\n "value": ""\n }\n ],\n "allowanceCharge": "",\n "allowanceCharges": [\n {\n "amountExcludingTax": "",\n "baseAmountExcludingTax": "",\n "reason": "",\n "reasonCode": ""\n }\n ],\n "amountExcludingTax": "",\n "amountExcludingVat": "",\n "amountIncludingTax": "",\n "buyersItemIdentification": "",\n "description": "",\n "invoicePeriod": "",\n "itemPrice": "",\n "lineId": "",\n "name": "",\n "note": "",\n "orderLineReferenceLineId": "",\n "quantity": "",\n "quantityUnitCode": "",\n "references": [\n {\n "documentId": "",\n "documentType": "",\n "issueDate": "",\n "lineId": ""\n }\n ],\n "sellersItemIdentification": "",\n "standardItemIdentification": "",\n "standardItemIdentificationSchemeAgencyId": "",\n "standardItemIdentificationSchemeId": "",\n "tax": {},\n "taxesDutiesFees": [\n {}\n ]\n }\n ],\n "invoiceNumber": "",\n "invoicePeriod": "",\n "invoiceType": "",\n "issueDate": "",\n "issueReasons": [],\n "note": "",\n "orderReference": "",\n "paymentMeansArray": [\n {\n "account": "",\n "amount": "",\n "branche_code": "",\n "code": "",\n "holder": "",\n "mandate": "",\n "network": "",\n "paymentId": ""\n }\n ],\n "paymentMeansBic": "",\n "paymentMeansCode": "",\n "paymentMeansIban": "",\n "paymentMeansPaymentId": "",\n "paymentTerms": {\n "note": ""\n },\n "preferredInvoiceType": "",\n "prepaidAmount": "",\n "priceMode": "",\n "projectReference": "",\n "references": [\n {}\n ],\n "salesOrderId": "",\n "selfBillingMode": false,\n "taxExemptReason": "",\n "taxPointDate": "",\n "taxSubtotals": [\n {\n "category": "",\n "country": "",\n "percentage": "",\n "taxAmount": "",\n "taxableAmount": ""\n }\n ],\n "taxSystem": "",\n "taxesDutiesFees": [\n {}\n ],\n "transactionType": "",\n "ublExtensions": [],\n "vatReverseCharge": false,\n "x2y": ""\n },\n "invoiceData": {\n "conversionStrategy": "",\n "document": ""\n },\n "invoiceRecipient": {\n "emails": [],\n "publicIdentifiers": [\n {}\n ]\n },\n "legalEntityId": 0,\n "legalSupplierId": 0,\n "mode": "",\n "routing": {\n "clearWithoutSending": false,\n "eIdentifiers": [\n {\n "id": "",\n "scheme": ""\n }\n ],\n "emails": []\n },\n "supplierId": 0\n}' \
--output-document \
- {{baseUrl}}/invoice_submissions
import Foundation
let headers = ["content-type": "application/json"]
let parameters = [
"attachments": [
[
"description": "",
"document": "",
"documentId": "",
"filename": "",
"mimeType": "",
"primaryImage": false
]
],
"createPrimaryImage": false,
"document": "",
"documentUrl": "",
"idempotencyGuid": "",
"invoice": [
"accountingCost": "",
"accountingCurrencyTaxAmount": "",
"accountingCurrencyTaxAmountCurrency": "",
"accountingCustomerParty": [
"party": [
"address": [
"city": "",
"country": "",
"county": "",
"street1": "",
"street2": "",
"zip": ""
],
"companyName": "",
"contact": [
"email": "",
"firstName": "",
"id": "",
"lastName": "",
"phone": ""
]
],
"publicIdentifiers": [
[
"id": "",
"scheme": ""
]
]
],
"accountingSupplierParty": ["party": ["contact": []]],
"allowanceCharges": [
[
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"baseAmountExcludingTax": "",
"baseAmountIncludingTax": "",
"reason": "",
"reasonCode": "",
"tax": [
"amount": "",
"category": "",
"country": "",
"percentage": ""
],
"taxesDutiesFees": [[]]
]
],
"amountIncludingVat": "",
"attachments": [[]],
"billingReference": "",
"buyerReference": "",
"consumerTaxMode": false,
"contractDocumentReference": "",
"delivery": [
"actualDate": "",
"deliveryLocation": [
"address": [],
"id": "",
"locationName": "",
"schemeAgencyId": "",
"schemeId": ""
],
"deliveryParty": ["party": []],
"deliveryPartyName": "",
"quantity": "",
"requestedDeliveryPeriod": "",
"shippingMarks": ""
],
"documentCurrencyCode": "",
"dueDate": "",
"invoiceLines": [
[
"accountingCost": "",
"additionalItemProperties": [
[
"name": "",
"value": ""
]
],
"allowanceCharge": "",
"allowanceCharges": [
[
"amountExcludingTax": "",
"baseAmountExcludingTax": "",
"reason": "",
"reasonCode": ""
]
],
"amountExcludingTax": "",
"amountExcludingVat": "",
"amountIncludingTax": "",
"buyersItemIdentification": "",
"description": "",
"invoicePeriod": "",
"itemPrice": "",
"lineId": "",
"name": "",
"note": "",
"orderLineReferenceLineId": "",
"quantity": "",
"quantityUnitCode": "",
"references": [
[
"documentId": "",
"documentType": "",
"issueDate": "",
"lineId": ""
]
],
"sellersItemIdentification": "",
"standardItemIdentification": "",
"standardItemIdentificationSchemeAgencyId": "",
"standardItemIdentificationSchemeId": "",
"tax": [],
"taxesDutiesFees": [[]]
]
],
"invoiceNumber": "",
"invoicePeriod": "",
"invoiceType": "",
"issueDate": "",
"issueReasons": [],
"note": "",
"orderReference": "",
"paymentMeansArray": [
[
"account": "",
"amount": "",
"branche_code": "",
"code": "",
"holder": "",
"mandate": "",
"network": "",
"paymentId": ""
]
],
"paymentMeansBic": "",
"paymentMeansCode": "",
"paymentMeansIban": "",
"paymentMeansPaymentId": "",
"paymentTerms": ["note": ""],
"preferredInvoiceType": "",
"prepaidAmount": "",
"priceMode": "",
"projectReference": "",
"references": [[]],
"salesOrderId": "",
"selfBillingMode": false,
"taxExemptReason": "",
"taxPointDate": "",
"taxSubtotals": [
[
"category": "",
"country": "",
"percentage": "",
"taxAmount": "",
"taxableAmount": ""
]
],
"taxSystem": "",
"taxesDutiesFees": [[]],
"transactionType": "",
"ublExtensions": [],
"vatReverseCharge": false,
"x2y": ""
],
"invoiceData": [
"conversionStrategy": "",
"document": ""
],
"invoiceRecipient": [
"emails": [],
"publicIdentifiers": [[]]
],
"legalEntityId": 0,
"legalSupplierId": 0,
"mode": "",
"routing": [
"clearWithoutSending": false,
"eIdentifiers": [
[
"id": "",
"scheme": ""
]
],
"emails": []
],
"supplierId": 0
] as [String : Any]
let postData = JSONSerialization.data(withJSONObject: parameters, options: [])
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/invoice_submissions")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
POST
Create a new LegalEntity
{{baseUrl}}/legal_entities
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/post "{{baseUrl}}/legal_entities")
require "http/client"
url = "{{baseUrl}}/legal_entities"
response = HTTP::Client.post url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("{{baseUrl}}/legal_entities"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities");
var request = new RestRequest("", Method.Post);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /baseUrl/legal_entities HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/legal_entities")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities"))
.method("POST", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities")
.post(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/legal_entities")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('POST', '{{baseUrl}}/legal_entities');
xhr.send(data);
import axios from 'axios';
const options = {method: 'POST', url: '{{baseUrl}}/legal_entities'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities';
const options = {method: 'POST'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities',
method: 'POST',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities")
.post(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'POST',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {method: 'POST', url: '{{baseUrl}}/legal_entities'};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('POST', '{{baseUrl}}/legal_entities');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {method: 'POST', url: '{{baseUrl}}/legal_entities'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities';
const options = {method: 'POST'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities" in
Client.call `POST uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('POST', '{{baseUrl}}/legal_entities');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities');
$request->setMethod(HTTP_METH_POST);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities');
$request->setRequestMethod('POST');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities' -Method POST
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities' -Method POST
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("POST", "/baseUrl/legal_entities")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities"
response = requests.post(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities"
response <- VERB("POST", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.post('/baseUrl/legal_entities') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities";
let client = reqwest::Client::new();
let response = client.post(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request POST \
--url {{baseUrl}}/legal_entities
http POST {{baseUrl}}/legal_entities
wget --quiet \
--method POST \
--output-document \
- {{baseUrl}}/legal_entities
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "POST"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
DELETE
Delete LegalEntity
{{baseUrl}}/legal_entities/:id
QUERY PARAMS
id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:id");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/delete "{{baseUrl}}/legal_entities/:id")
require "http/client"
url = "{{baseUrl}}/legal_entities/:id"
response = HTTP::Client.delete url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Delete,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:id"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:id");
var request = new RestRequest("", Method.Delete);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:id"
req, _ := http.NewRequest("DELETE", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
DELETE /baseUrl/legal_entities/:id HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("DELETE", "{{baseUrl}}/legal_entities/:id")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:id"))
.method("DELETE", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:id")
.delete(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.delete("{{baseUrl}}/legal_entities/:id")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('DELETE', '{{baseUrl}}/legal_entities/:id');
xhr.send(data);
import axios from 'axios';
const options = {method: 'DELETE', url: '{{baseUrl}}/legal_entities/:id'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:id';
const options = {method: 'DELETE'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:id',
method: 'DELETE',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:id")
.delete(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'DELETE',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:id',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {method: 'DELETE', url: '{{baseUrl}}/legal_entities/:id'};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('DELETE', '{{baseUrl}}/legal_entities/:id');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {method: 'DELETE', url: '{{baseUrl}}/legal_entities/:id'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:id';
const options = {method: 'DELETE'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:id"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"DELETE"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:id" in
Client.call `DELETE uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('DELETE', '{{baseUrl}}/legal_entities/:id');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:id');
$request->setMethod(HTTP_METH_DELETE);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:id');
$request->setRequestMethod('DELETE');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:id' -Method DELETE
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:id' -Method DELETE
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("DELETE", "/baseUrl/legal_entities/:id")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:id"
response = requests.delete(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:id"
response <- VERB("DELETE", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:id")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.delete('/baseUrl/legal_entities/:id') do |req|
end
puts response.status
puts response.body
use std::str::FromStr;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:id";
let client = reqwest::Client::new();
let response = client.request(reqwest::Method::from_str("DELETE").unwrap(), url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request DELETE \
--url {{baseUrl}}/legal_entities/:id
http DELETE {{baseUrl}}/legal_entities/:id
wget --quiet \
--method DELETE \
--output-document \
- {{baseUrl}}/legal_entities/:id
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:id")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "DELETE"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
GET
Get LegalEntity
{{baseUrl}}/legal_entities/:id
QUERY PARAMS
id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:id");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/get "{{baseUrl}}/legal_entities/:id")
require "http/client"
url = "{{baseUrl}}/legal_entities/:id"
response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:id"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:id");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:id"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /baseUrl/legal_entities/:id HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/legal_entities/:id")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:id"))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:id")
.get()
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/legal_entities/:id")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('GET', '{{baseUrl}}/legal_entities/:id');
xhr.send(data);
import axios from 'axios';
const options = {method: 'GET', url: '{{baseUrl}}/legal_entities/:id'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:id';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:id',
method: 'GET',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:id")
.get()
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'GET',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:id',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {method: 'GET', url: '{{baseUrl}}/legal_entities/:id'};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('GET', '{{baseUrl}}/legal_entities/:id');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {method: 'GET', url: '{{baseUrl}}/legal_entities/:id'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:id';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:id"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:id" in
Client.call `GET uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('GET', '{{baseUrl}}/legal_entities/:id');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:id');
$request->setMethod(HTTP_METH_GET);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:id');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:id' -Method GET
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:id' -Method GET
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("GET", "/baseUrl/legal_entities/:id")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:id"
response = requests.get(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:id"
response <- VERB("GET", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:id")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.get('/baseUrl/legal_entities/:id') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:id";
let client = reqwest::Client::new();
let response = client.get(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request GET \
--url {{baseUrl}}/legal_entities/:id
http GET {{baseUrl}}/legal_entities/:id
wget --quiet \
--method GET \
--output-document \
- {{baseUrl}}/legal_entities/:id
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:id")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "GET"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
PATCH
Update LegalEntity
{{baseUrl}}/legal_entities/:id
QUERY PARAMS
id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "PATCH");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:id");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/patch "{{baseUrl}}/legal_entities/:id")
require "http/client"
url = "{{baseUrl}}/legal_entities/:id"
response = HTTP::Client.patch url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Patch,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:id"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:id");
var request = new RestRequest("", Method.Patch);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:id"
req, _ := http.NewRequest("PATCH", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
PATCH /baseUrl/legal_entities/:id HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("PATCH", "{{baseUrl}}/legal_entities/:id")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:id"))
.method("PATCH", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:id")
.patch(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.patch("{{baseUrl}}/legal_entities/:id")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('PATCH', '{{baseUrl}}/legal_entities/:id');
xhr.send(data);
import axios from 'axios';
const options = {method: 'PATCH', url: '{{baseUrl}}/legal_entities/:id'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:id';
const options = {method: 'PATCH'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:id',
method: 'PATCH',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:id")
.patch(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'PATCH',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:id',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {method: 'PATCH', url: '{{baseUrl}}/legal_entities/:id'};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('PATCH', '{{baseUrl}}/legal_entities/:id');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {method: 'PATCH', url: '{{baseUrl}}/legal_entities/:id'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:id';
const options = {method: 'PATCH'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:id"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"PATCH"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:id" in
Client.call `PATCH uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('PATCH', '{{baseUrl}}/legal_entities/:id');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:id');
$request->setMethod(HttpRequest::HTTP_METH_PATCH);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:id');
$request->setRequestMethod('PATCH');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:id' -Method PATCH
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:id' -Method PATCH
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("PATCH", "/baseUrl/legal_entities/:id")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:id"
response = requests.patch(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:id"
response <- VERB("PATCH", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:id")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.patch('/baseUrl/legal_entities/:id') do |req|
end
puts response.status
puts response.body
use std::str::FromStr;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:id";
let client = reqwest::Client::new();
let response = client.request(reqwest::Method::from_str("PATCH").unwrap(), url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request PATCH \
--url {{baseUrl}}/legal_entities/:id
http PATCH {{baseUrl}}/legal_entities/:id
wget --quiet \
--method PATCH \
--output-document \
- {{baseUrl}}/legal_entities/:id
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:id")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "PATCH"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
POST
Create a new PeppolIdentifier
{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers
QUERY PARAMS
legal_entity_id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/post "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers")
require "http/client"
url = "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers"
response = HTTP::Client.post url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers");
var request = new RestRequest("", Method.Post);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /baseUrl/legal_entities/:legal_entity_id/peppol_identifiers HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers"))
.method("POST", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers")
.post(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('POST', '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'POST',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers';
const options = {method: 'POST'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers',
method: 'POST',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers")
.post(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'POST',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:legal_entity_id/peppol_identifiers',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'POST',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('POST', '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'POST',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers';
const options = {method: 'POST'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers" in
Client.call `POST uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('POST', '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers');
$request->setMethod(HTTP_METH_POST);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers');
$request->setRequestMethod('POST');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers' -Method POST
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers' -Method POST
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("POST", "/baseUrl/legal_entities/:legal_entity_id/peppol_identifiers")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers"
response = requests.post(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers"
response <- VERB("POST", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.post('/baseUrl/legal_entities/:legal_entity_id/peppol_identifiers') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers";
let client = reqwest::Client::new();
let response = client.post(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request POST \
--url {{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers
http POST {{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers
wget --quiet \
--method POST \
--output-document \
- {{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "POST"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
DELETE
Delete PeppolIdentifier
{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier
QUERY PARAMS
legal_entity_id
superscheme
scheme
identifier
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/delete "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier")
require "http/client"
url = "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier"
response = HTTP::Client.delete url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Delete,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier");
var request = new RestRequest("", Method.Delete);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier"
req, _ := http.NewRequest("DELETE", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
DELETE /baseUrl/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("DELETE", "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier"))
.method("DELETE", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier")
.delete(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.delete("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('DELETE', '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'DELETE',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier';
const options = {method: 'DELETE'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier',
method: 'DELETE',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier")
.delete(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'DELETE',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'DELETE',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('DELETE', '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'DELETE',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier';
const options = {method: 'DELETE'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"DELETE"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier" in
Client.call `DELETE uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('DELETE', '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier');
$request->setMethod(HTTP_METH_DELETE);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier');
$request->setRequestMethod('DELETE');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier' -Method DELETE
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier' -Method DELETE
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("DELETE", "/baseUrl/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier"
response = requests.delete(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier"
response <- VERB("DELETE", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.delete('/baseUrl/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier') do |req|
end
puts response.status
puts response.body
use std::str::FromStr;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier";
let client = reqwest::Client::new();
let response = client.request(reqwest::Method::from_str("DELETE").unwrap(), url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request DELETE \
--url {{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier
http DELETE {{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier
wget --quiet \
--method DELETE \
--output-document \
- {{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:legal_entity_id/peppol_identifiers/:superscheme/:scheme/:identifier")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "DELETE"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
GET
Get Purchase invoice data as JSON with a Base64-encoded UBL string in the specified version
{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version
QUERY PARAMS
guid
packaging
package_version
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/get "{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version")
require "http/client"
url = "{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version"
response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /baseUrl/purchase_invoices/:guid/:packaging/:package_version HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version"))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version")
.get()
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('GET', '{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'GET',
url: '{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version',
method: 'GET',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version")
.get()
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'GET',
hostname: 'example.com',
port: null,
path: '/baseUrl/purchase_invoices/:guid/:packaging/:package_version',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'GET',
url: '{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('GET', '{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'GET',
url: '{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version" in
Client.call `GET uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('GET', '{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version');
echo $response->getBody();
setUrl('{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version');
$request->setMethod(HTTP_METH_GET);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version' -Method GET
$response = Invoke-RestMethod -Uri '{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version' -Method GET
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("GET", "/baseUrl/purchase_invoices/:guid/:packaging/:package_version")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version"
response = requests.get(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version"
response <- VERB("GET", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.get('/baseUrl/purchase_invoices/:guid/:packaging/:package_version') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version";
let client = reqwest::Client::new();
let response = client.get(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request GET \
--url {{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version
http GET {{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version
wget --quiet \
--method GET \
--output-document \
- {{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/purchase_invoices/:guid/:packaging/:package_version")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "GET"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
GET
Get Purchase invoice data as JSON
{{baseUrl}}/purchase_invoices/:guid
QUERY PARAMS
guid
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/purchase_invoices/:guid");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/get "{{baseUrl}}/purchase_invoices/:guid")
require "http/client"
url = "{{baseUrl}}/purchase_invoices/:guid"
response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("{{baseUrl}}/purchase_invoices/:guid"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/purchase_invoices/:guid");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/purchase_invoices/:guid"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /baseUrl/purchase_invoices/:guid HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/purchase_invoices/:guid")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/purchase_invoices/:guid"))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/purchase_invoices/:guid")
.get()
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/purchase_invoices/:guid")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('GET', '{{baseUrl}}/purchase_invoices/:guid');
xhr.send(data);
import axios from 'axios';
const options = {method: 'GET', url: '{{baseUrl}}/purchase_invoices/:guid'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/purchase_invoices/:guid';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/purchase_invoices/:guid',
method: 'GET',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/purchase_invoices/:guid")
.get()
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'GET',
hostname: 'example.com',
port: null,
path: '/baseUrl/purchase_invoices/:guid',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {method: 'GET', url: '{{baseUrl}}/purchase_invoices/:guid'};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('GET', '{{baseUrl}}/purchase_invoices/:guid');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {method: 'GET', url: '{{baseUrl}}/purchase_invoices/:guid'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/purchase_invoices/:guid';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/purchase_invoices/:guid"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/purchase_invoices/:guid" in
Client.call `GET uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/purchase_invoices/:guid",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('GET', '{{baseUrl}}/purchase_invoices/:guid');
echo $response->getBody();
setUrl('{{baseUrl}}/purchase_invoices/:guid');
$request->setMethod(HTTP_METH_GET);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/purchase_invoices/:guid');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/purchase_invoices/:guid' -Method GET
$response = Invoke-RestMethod -Uri '{{baseUrl}}/purchase_invoices/:guid' -Method GET
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("GET", "/baseUrl/purchase_invoices/:guid")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/purchase_invoices/:guid"
response = requests.get(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/purchase_invoices/:guid"
response <- VERB("GET", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/purchase_invoices/:guid")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.get('/baseUrl/purchase_invoices/:guid') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/purchase_invoices/:guid";
let client = reqwest::Client::new();
let response = client.get(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request GET \
--url {{baseUrl}}/purchase_invoices/:guid
http GET {{baseUrl}}/purchase_invoices/:guid
wget --quiet \
--method GET \
--output-document \
- {{baseUrl}}/purchase_invoices/:guid
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/purchase_invoices/:guid")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "GET"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
GET
Get Purchase invoice data in a selectable format
{{baseUrl}}/purchase_invoices/:guid/:packaging
QUERY PARAMS
guid
packaging
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/purchase_invoices/:guid/:packaging");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/get "{{baseUrl}}/purchase_invoices/:guid/:packaging")
require "http/client"
url = "{{baseUrl}}/purchase_invoices/:guid/:packaging"
response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("{{baseUrl}}/purchase_invoices/:guid/:packaging"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/purchase_invoices/:guid/:packaging");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/purchase_invoices/:guid/:packaging"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /baseUrl/purchase_invoices/:guid/:packaging HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/purchase_invoices/:guid/:packaging")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/purchase_invoices/:guid/:packaging"))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/purchase_invoices/:guid/:packaging")
.get()
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/purchase_invoices/:guid/:packaging")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('GET', '{{baseUrl}}/purchase_invoices/:guid/:packaging');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'GET',
url: '{{baseUrl}}/purchase_invoices/:guid/:packaging'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/purchase_invoices/:guid/:packaging';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/purchase_invoices/:guid/:packaging',
method: 'GET',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/purchase_invoices/:guid/:packaging")
.get()
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'GET',
hostname: 'example.com',
port: null,
path: '/baseUrl/purchase_invoices/:guid/:packaging',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'GET',
url: '{{baseUrl}}/purchase_invoices/:guid/:packaging'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('GET', '{{baseUrl}}/purchase_invoices/:guid/:packaging');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'GET',
url: '{{baseUrl}}/purchase_invoices/:guid/:packaging'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/purchase_invoices/:guid/:packaging';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/purchase_invoices/:guid/:packaging"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/purchase_invoices/:guid/:packaging" in
Client.call `GET uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/purchase_invoices/:guid/:packaging",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('GET', '{{baseUrl}}/purchase_invoices/:guid/:packaging');
echo $response->getBody();
setUrl('{{baseUrl}}/purchase_invoices/:guid/:packaging');
$request->setMethod(HTTP_METH_GET);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/purchase_invoices/:guid/:packaging');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/purchase_invoices/:guid/:packaging' -Method GET
$response = Invoke-RestMethod -Uri '{{baseUrl}}/purchase_invoices/:guid/:packaging' -Method GET
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("GET", "/baseUrl/purchase_invoices/:guid/:packaging")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/purchase_invoices/:guid/:packaging"
response = requests.get(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/purchase_invoices/:guid/:packaging"
response <- VERB("GET", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/purchase_invoices/:guid/:packaging")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.get('/baseUrl/purchase_invoices/:guid/:packaging') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/purchase_invoices/:guid/:packaging";
let client = reqwest::Client::new();
let response = client.get(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request GET \
--url {{baseUrl}}/purchase_invoices/:guid/:packaging
http GET {{baseUrl}}/purchase_invoices/:guid/:packaging
wget --quiet \
--method GET \
--output-document \
- {{baseUrl}}/purchase_invoices/:guid/:packaging
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/purchase_invoices/:guid/:packaging")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "GET"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
GET
Get a new ReceivedDocument
{{baseUrl}}/received_documents/:guid/:format
QUERY PARAMS
syntax
guid
format
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/received_documents/:guid/:format?syntax=");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/get "{{baseUrl}}/received_documents/:guid/:format" {:query-params {:syntax ""}})
require "http/client"
url = "{{baseUrl}}/received_documents/:guid/:format?syntax="
response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("{{baseUrl}}/received_documents/:guid/:format?syntax="),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/received_documents/:guid/:format?syntax=");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/received_documents/:guid/:format?syntax="
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /baseUrl/received_documents/:guid/:format?syntax= HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/received_documents/:guid/:format?syntax=")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/received_documents/:guid/:format?syntax="))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/received_documents/:guid/:format?syntax=")
.get()
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/received_documents/:guid/:format?syntax=")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('GET', '{{baseUrl}}/received_documents/:guid/:format?syntax=');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'GET',
url: '{{baseUrl}}/received_documents/:guid/:format',
params: {syntax: ''}
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/received_documents/:guid/:format?syntax=';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/received_documents/:guid/:format?syntax=',
method: 'GET',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/received_documents/:guid/:format?syntax=")
.get()
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'GET',
hostname: 'example.com',
port: null,
path: '/baseUrl/received_documents/:guid/:format?syntax=',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'GET',
url: '{{baseUrl}}/received_documents/:guid/:format',
qs: {syntax: ''}
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('GET', '{{baseUrl}}/received_documents/:guid/:format');
req.query({
syntax: ''
});
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'GET',
url: '{{baseUrl}}/received_documents/:guid/:format',
params: {syntax: ''}
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/received_documents/:guid/:format?syntax=';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/received_documents/:guid/:format?syntax="]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/received_documents/:guid/:format?syntax=" in
Client.call `GET uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/received_documents/:guid/:format?syntax=",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('GET', '{{baseUrl}}/received_documents/:guid/:format?syntax=');
echo $response->getBody();
setUrl('{{baseUrl}}/received_documents/:guid/:format');
$request->setMethod(HTTP_METH_GET);
$request->setQueryData([
'syntax' => ''
]);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/received_documents/:guid/:format');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString([
'syntax' => ''
]));
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/received_documents/:guid/:format?syntax=' -Method GET
$response = Invoke-RestMethod -Uri '{{baseUrl}}/received_documents/:guid/:format?syntax=' -Method GET
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("GET", "/baseUrl/received_documents/:guid/:format?syntax=")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/received_documents/:guid/:format"
querystring = {"syntax":""}
response = requests.get(url, params=querystring)
print(response.json())
library(httr)
url <- "{{baseUrl}}/received_documents/:guid/:format"
queryString <- list(syntax = "")
response <- VERB("GET", url, query = queryString, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/received_documents/:guid/:format?syntax=")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.get('/baseUrl/received_documents/:guid/:format') do |req|
req.params['syntax'] = ''
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/received_documents/:guid/:format";
let querystring = [
("syntax", ""),
];
let client = reqwest::Client::new();
let response = client.get(url)
.query(&querystring)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request GET \
--url '{{baseUrl}}/received_documents/:guid/:format?syntax='
http GET '{{baseUrl}}/received_documents/:guid/:format?syntax='
wget --quiet \
--method GET \
--output-document \
- '{{baseUrl}}/received_documents/:guid/:format?syntax='
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/received_documents/:guid/:format?syntax=")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "GET"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
POST
Receive a new Document
{{baseUrl}}/legal_entities/:legal_entity_id/received_documents
QUERY PARAMS
legal_entity_id
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/legal_entities/:legal_entity_id/received_documents");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/post "{{baseUrl}}/legal_entities/:legal_entity_id/received_documents")
require "http/client"
url = "{{baseUrl}}/legal_entities/:legal_entity_id/received_documents"
response = HTTP::Client.post url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("{{baseUrl}}/legal_entities/:legal_entity_id/received_documents"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/legal_entities/:legal_entity_id/received_documents");
var request = new RestRequest("", Method.Post);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/legal_entities/:legal_entity_id/received_documents"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /baseUrl/legal_entities/:legal_entity_id/received_documents HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/legal_entities/:legal_entity_id/received_documents")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/legal_entities/:legal_entity_id/received_documents"))
.method("POST", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/received_documents")
.post(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/legal_entities/:legal_entity_id/received_documents")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('POST', '{{baseUrl}}/legal_entities/:legal_entity_id/received_documents');
xhr.send(data);
import axios from 'axios';
const options = {
method: 'POST',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/received_documents'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/received_documents';
const options = {method: 'POST'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/legal_entities/:legal_entity_id/received_documents',
method: 'POST',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/legal_entities/:legal_entity_id/received_documents")
.post(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'POST',
hostname: 'example.com',
port: null,
path: '/baseUrl/legal_entities/:legal_entity_id/received_documents',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {
method: 'POST',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/received_documents'
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('POST', '{{baseUrl}}/legal_entities/:legal_entity_id/received_documents');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {
method: 'POST',
url: '{{baseUrl}}/legal_entities/:legal_entity_id/received_documents'
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/legal_entities/:legal_entity_id/received_documents';
const options = {method: 'POST'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/legal_entities/:legal_entity_id/received_documents"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/legal_entities/:legal_entity_id/received_documents" in
Client.call `POST uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/legal_entities/:legal_entity_id/received_documents",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('POST', '{{baseUrl}}/legal_entities/:legal_entity_id/received_documents');
echo $response->getBody();
setUrl('{{baseUrl}}/legal_entities/:legal_entity_id/received_documents');
$request->setMethod(HTTP_METH_POST);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/legal_entities/:legal_entity_id/received_documents');
$request->setRequestMethod('POST');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/received_documents' -Method POST
$response = Invoke-RestMethod -Uri '{{baseUrl}}/legal_entities/:legal_entity_id/received_documents' -Method POST
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("POST", "/baseUrl/legal_entities/:legal_entity_id/received_documents")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/legal_entities/:legal_entity_id/received_documents"
response = requests.post(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/legal_entities/:legal_entity_id/received_documents"
response <- VERB("POST", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/legal_entities/:legal_entity_id/received_documents")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.post('/baseUrl/legal_entities/:legal_entity_id/received_documents') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/legal_entities/:legal_entity_id/received_documents";
let client = reqwest::Client::new();
let response = client.post(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request POST \
--url {{baseUrl}}/legal_entities/:legal_entity_id/received_documents
http POST {{baseUrl}}/legal_entities/:legal_entity_id/received_documents
wget --quiet \
--method POST \
--output-document \
- {{baseUrl}}/legal_entities/:legal_entity_id/received_documents
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/legal_entities/:legal_entity_id/received_documents")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "POST"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
DELETE
DELETE a WebhookInstance
{{baseUrl}}/webhook_instances/:guid
QUERY PARAMS
guid
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/webhook_instances/:guid");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/delete "{{baseUrl}}/webhook_instances/:guid")
require "http/client"
url = "{{baseUrl}}/webhook_instances/:guid"
response = HTTP::Client.delete url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Delete,
RequestUri = new Uri("{{baseUrl}}/webhook_instances/:guid"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/webhook_instances/:guid");
var request = new RestRequest("", Method.Delete);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/webhook_instances/:guid"
req, _ := http.NewRequest("DELETE", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
DELETE /baseUrl/webhook_instances/:guid HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("DELETE", "{{baseUrl}}/webhook_instances/:guid")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/webhook_instances/:guid"))
.method("DELETE", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/webhook_instances/:guid")
.delete(null)
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.delete("{{baseUrl}}/webhook_instances/:guid")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('DELETE', '{{baseUrl}}/webhook_instances/:guid');
xhr.send(data);
import axios from 'axios';
const options = {method: 'DELETE', url: '{{baseUrl}}/webhook_instances/:guid'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/webhook_instances/:guid';
const options = {method: 'DELETE'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/webhook_instances/:guid',
method: 'DELETE',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/webhook_instances/:guid")
.delete(null)
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'DELETE',
hostname: 'example.com',
port: null,
path: '/baseUrl/webhook_instances/:guid',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {method: 'DELETE', url: '{{baseUrl}}/webhook_instances/:guid'};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('DELETE', '{{baseUrl}}/webhook_instances/:guid');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {method: 'DELETE', url: '{{baseUrl}}/webhook_instances/:guid'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/webhook_instances/:guid';
const options = {method: 'DELETE'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/webhook_instances/:guid"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"DELETE"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/webhook_instances/:guid" in
Client.call `DELETE uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/webhook_instances/:guid",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('DELETE', '{{baseUrl}}/webhook_instances/:guid');
echo $response->getBody();
setUrl('{{baseUrl}}/webhook_instances/:guid');
$request->setMethod(HTTP_METH_DELETE);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/webhook_instances/:guid');
$request->setRequestMethod('DELETE');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/webhook_instances/:guid' -Method DELETE
$response = Invoke-RestMethod -Uri '{{baseUrl}}/webhook_instances/:guid' -Method DELETE
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("DELETE", "/baseUrl/webhook_instances/:guid")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/webhook_instances/:guid"
response = requests.delete(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/webhook_instances/:guid"
response <- VERB("DELETE", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/webhook_instances/:guid")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.delete('/baseUrl/webhook_instances/:guid') do |req|
end
puts response.status
puts response.body
use std::str::FromStr;
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/webhook_instances/:guid";
let client = reqwest::Client::new();
let response = client.request(reqwest::Method::from_str("DELETE").unwrap(), url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request DELETE \
--url {{baseUrl}}/webhook_instances/:guid
http DELETE {{baseUrl}}/webhook_instances/:guid
wget --quiet \
--method DELETE \
--output-document \
- {{baseUrl}}/webhook_instances/:guid
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/webhook_instances/:guid")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "DELETE"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()
GET
GET a WebhookInstance
{{baseUrl}}/webhook_instances/
Examples
REQUEST
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/webhook_instances/");
CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])
(client/get "{{baseUrl}}/webhook_instances/")
require "http/client"
url = "{{baseUrl}}/webhook_instances/"
response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("{{baseUrl}}/webhook_instances/"),
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/webhook_instances/");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{baseUrl}}/webhook_instances/"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /baseUrl/webhook_instances/ HTTP/1.1
Host: example.com
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/webhook_instances/")
.execute()
.toCompletableFuture()
.thenAccept(System.out::println)
.join();
client.close();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("{{baseUrl}}/webhook_instances/"))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("{{baseUrl}}/webhook_instances/")
.get()
.build();
Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/webhook_instances/")
.asString();
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener('readystatechange', function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open('GET', '{{baseUrl}}/webhook_instances/');
xhr.send(data);
import axios from 'axios';
const options = {method: 'GET', url: '{{baseUrl}}/webhook_instances/'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const url = '{{baseUrl}}/webhook_instances/';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
const settings = {
async: true,
crossDomain: true,
url: '{{baseUrl}}/webhook_instances/',
method: 'GET',
headers: {}
};
$.ajax(settings).done(function (response) {
console.log(response);
});
val client = OkHttpClient()
val request = Request.Builder()
.url("{{baseUrl}}/webhook_instances/")
.get()
.build()
val response = client.newCall(request).execute()
const http = require('https');
const options = {
method: 'GET',
hostname: 'example.com',
port: null,
path: '/baseUrl/webhook_instances/',
headers: {}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on('data', function (chunk) {
chunks.push(chunk);
});
res.on('end', function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
const request = require('request');
const options = {method: 'GET', url: '{{baseUrl}}/webhook_instances/'};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
const unirest = require('unirest');
const req = unirest('GET', '{{baseUrl}}/webhook_instances/');
req.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.body);
});
const axios = require('axios').default;
const options = {method: 'GET', url: '{{baseUrl}}/webhook_instances/'};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}
const fetch = require('node-fetch');
const url = '{{baseUrl}}/webhook_instances/';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
#import
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/webhook_instances/"]
cachePolicy:NSURLRequestUseProtocolCachePolicy
timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];
NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
if (error) {
NSLog(@"%@", error);
} else {
NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
NSLog(@"%@", httpResponse);
}
}];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt
let uri = Uri.of_string "{{baseUrl}}/webhook_instances/" in
Client.call `GET uri
>>= fun (res, body_stream) ->
(* Do stuff with the result *)
"{{baseUrl}}/webhook_instances/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
request('GET', '{{baseUrl}}/webhook_instances/');
echo $response->getBody();
setUrl('{{baseUrl}}/webhook_instances/');
$request->setMethod(HTTP_METH_GET);
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}
setRequestUrl('{{baseUrl}}/webhook_instances/');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/webhook_instances/' -Method GET
$response = Invoke-RestMethod -Uri '{{baseUrl}}/webhook_instances/' -Method GET
import http.client
conn = http.client.HTTPSConnection("example.com")
conn.request("GET", "/baseUrl/webhook_instances/")
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "{{baseUrl}}/webhook_instances/"
response = requests.get(url)
print(response.json())
library(httr)
url <- "{{baseUrl}}/webhook_instances/"
response <- VERB("GET", url, content_type("application/octet-stream"))
content(response, "text")
require 'uri'
require 'net/http'
url = URI("{{baseUrl}}/webhook_instances/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body
require 'faraday'
conn = Faraday.new(
url: 'https://example.com',
)
response = conn.get('/baseUrl/webhook_instances/') do |req|
end
puts response.status
puts response.body
use reqwest;
#[tokio::main]
pub async fn main() {
let url = "{{baseUrl}}/webhook_instances/";
let client = reqwest::Client::new();
let response = client.get(url)
.send()
.await;
let results = response.unwrap()
.json::()
.await
.unwrap();
dbg!(results);
}
curl --request GET \
--url {{baseUrl}}/webhook_instances/
http GET {{baseUrl}}/webhook_instances/
wget --quiet \
--method GET \
--output-document \
- {{baseUrl}}/webhook_instances/
import Foundation
let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/webhook_instances/")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "GET"
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()