Donation Receipt
Ausgestellte Zuwendungsbestätigungen
GET/api/invoice/donation_receipt
Antworten
200Liefert eine Liste der ausgestellten DonationReceipts.
Anfrage
curl --request GET \
--url https://eure-instanz.iw-erp.de/api/invoice/donation_receipt \
--header 'x-iw-jwt-token: <TOKEN>'const options = {method: 'GET', headers: {'x-iw-jwt-token': '<TOKEN>'}};
fetch('https://eure-instanz.iw-erp.de/api/invoice/donation_receipt', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://eure-instanz.iw-erp.de/api/invoice/donation_receipt"
headers = {"x-iw-jwt-token": "<TOKEN>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://eure-instanz.iw-erp.de/api/invoice/donation_receipt', [
'headers' => [
'x-iw-jwt-token' => '<TOKEN>',
],
]);
echo $response->getBody();using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("https://eure-instanz.iw-erp.de/api/invoice/donation_receipt"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/invoice/donation_receipt")
.get()
.addHeader("x-iw-jwt-token", "<TOKEN>")
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/invoice/donation_receipt"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-iw-jwt-token", "<TOKEN>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Dart mit package:http (kein Controller im Package iw_erp_api)
import 'package:http/http.dart' as http;
final response = await http.get(
Uri.parse('https://eure-instanz.iw-erp.de/api/invoice/donation_receipt'),
headers: {'x-iw-jwt-token': '<TOKEN>'},
);
print(response.body);Eine ausgestellte Zuwendungsbestätigung mit ihren Spenden
GET/api/invoice/donation_receipt/{id}
Pfad-Parameter
idPflichtstring |
Antworten
200Liefert ein einzelnes DonationReceipt-Objekt.
Anfrage
curl --request GET \
--url https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42 \
--header 'x-iw-jwt-token: <TOKEN>'const options = {method: 'GET', headers: {'x-iw-jwt-token': '<TOKEN>'}};
fetch('https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42"
headers = {"x-iw-jwt-token": "<TOKEN>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42', [
'headers' => [
'x-iw-jwt-token' => '<TOKEN>',
],
]);
echo $response->getBody();using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Get,
RequestUri = new Uri("https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42")
.get()
.addHeader("x-iw-jwt-token", "<TOKEN>")
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-iw-jwt-token", "<TOKEN>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Dart mit package:http (kein Controller im Package iw_erp_api)
import 'package:http/http.dart' as http;
final response = await http.get(
Uri.parse('https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42'),
headers: {'x-iw-jwt-token': '<TOKEN>'},
);
print(response.body);Zuwendungsbestätigung stornieren
POST/api/invoice/donation_receipt/{id}/cancel
Danach lassen sich die Spenden wieder ändern und neu bestätigen; die neue Bestätigung verweist auf die stornierte.
Pfad-Parameter
idPflichtstring |
Request-Body application/json
reasonstringGrund des Stornos
Antworten
200Die stornierte DonationReceipt
409Bereits storniert oder kein Grund angegeben
Anfrage
curl --request POST \
--url https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42/cancel \
--header 'content-type: application/json' \
--header 'x-iw-jwt-token: <TOKEN>' \
--data '{"reason":"string"}'const options = {
method: 'POST',
headers: {'x-iw-jwt-token': '<TOKEN>', 'content-type': 'application/json'},
body: JSON.stringify({reason: 'string'})
};
fetch('https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42/cancel', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42/cancel"
payload = { "reason": "string" }
headers = {
"x-iw-jwt-token": "<TOKEN>",
"content-type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('POST', 'https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42/cancel', [
'body' => '{"reason":"string"}',
'headers' => [
'content-type' => 'application/json',
'x-iw-jwt-token' => '<TOKEN>',
],
]);
echo $response->getBody();using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
Method = HttpMethod.Post,
RequestUri = new Uri("https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42/cancel"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
Content = new StringContent("{\"reason\":\"string\"}")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/json")
}
}
};
using (var response = await client.SendAsync(request))
{
response.EnsureSuccessStatusCode();
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\"reason\":\"string\"}");
Request request = new Request.Builder()
.url("https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42/cancel")
.post(body)
.addHeader("x-iw-jwt-token", "<TOKEN>")
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42/cancel"
payload := strings.NewReader("{\"reason\":\"string\"}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-iw-jwt-token", "<TOKEN>")
req.Header.Add("content-type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Dart mit package:http (kein Controller im Package iw_erp_api)
import 'dart:convert';
import 'package:http/http.dart' as http;
final response = await http.post(
Uri.parse('https://eure-instanz.iw-erp.de/api/invoice/donation_receipt/42/cancel'),
headers: {'x-iw-jwt-token': '<TOKEN>', 'content-type': 'application/json'},
body: jsonEncode({
"reason": "string"
}),
);
print(response.body);