EventTimingRead
Returns a list of event timing read entries.
GET/api/event/timing_read
Query parameters
idinteger | |
baseEventstring | |
timingPointstring | |
signUpstring | |
devicestring | |
rawBibstring | |
rawChipstring | |
readTimestring | |
readTimeMsstring | Unix time in milliseconds (device clock corrected by its offset). |
sourcestring | |
externalIdstring | Id of the read at its source (device sequence number, CSV row), used for idempotency. |
statusstring | |
createdstring | |
searchStringstring | text to search for in the list |
orderFieldNamestring | name of the order field |
orderFieldSortstring | sorting modeAllowed: DESCASC |
pageinteger | page of the list |
pageSizeinteger | number of entries for each page |
withMaxPageNumberstring | returns the number of pages available as a header if this is set |
Responses
200Returns a list of EventTimingRead objectsarray<EventTimingRead>
Show fields (19)
base_event_idintegertiming_point_idintegersign_up_idintegerbib_labelstringnamestringdevice_idintegerread_time_msintegerUnix time in milliseconds (device clock corrected by its offset).
idintegerPrimary key of the timing read. Internal ID.
raw_bibstringBib number as read by the device.
raw_chipstringChip ID as read by the device.
read_timestring (date-time)Time of the read.
sourcestringSource of the read, for example device or manual entry.
external_idstringId of the read at its source (device sequence number, CSV row), used for idempotency.
statusstringStatus of the read, for example matched or unknown.
latitudenumber (float)Latitude of the read in degrees, if known.
longitudenumber (float)Longitude of the read in degrees, if known.
accuracynumber (float)Accuracy of the position in meters.
notestringNote on the read.
createdstring (date-time)Time the read was stored.
curl --request GET \
--url https://your-instance.iw-erp.de/api/event/timing_read \
--header 'x-iw-jwt-token: <TOKEN>'const options = {method: 'GET', headers: {'x-iw-jwt-token': '<TOKEN>'}};
fetch('https://your-instance.iw-erp.de/api/event/timing_read', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://your-instance.iw-erp.de/api/event/timing_read"
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://your-instance.iw-erp.de/api/event/timing_read', [
'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://your-instance.iw-erp.de/api/event/timing_read"),
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://your-instance.iw-erp.de/api/event/timing_read")
.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://your-instance.iw-erp.de/api/event/timing_read"
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 with the iw_erp_api package
import 'package:iw_erp_api/clients/event_timing_read_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'your-instance.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await EventTimingReadController.getAll();
if (result.success) {
print(result.data);
}[
{
"name": "Beispiel",
"id": 42,
"base_event_id": 42,
"timing_point_id": 42,
"sign_up_id": 42,
"bib_label": "string",
"device_id": 42,
"read_time_ms": 1,
"raw_bib": "string",
"raw_chip": "string"
}
]Manual read, e.g. typed in at the finish line. Without read_time_ms the server time is used.
POST/api/event/timing_read
Request body application/json
base_eventintegertiming_pointintegerbibstringsign_upintegerread_time_msinteger
Responses
200{results: [ReadResult]}
curl --request POST \
--url https://your-instance.iw-erp.de/api/event/timing_read \
--header 'content-type: application/json' \
--header 'x-iw-jwt-token: <TOKEN>' \
--data '
{
"base_event": 1,
"timing_point": 1,
"bib": "string",
"sign_up": 1,
"read_time_ms": 1
}
'const options = {
method: 'POST',
headers: {'x-iw-jwt-token': '<TOKEN>', 'content-type': 'application/json'},
body: JSON.stringify({base_event: 1, timing_point: 1, bib: 'string', sign_up: 1, read_time_ms: 1})
};
fetch('https://your-instance.iw-erp.de/api/event/timing_read', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://your-instance.iw-erp.de/api/event/timing_read"
payload = {
"base_event": 1,
"timing_point": 1,
"bib": "string",
"sign_up": 1,
"read_time_ms": 1
}
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://your-instance.iw-erp.de/api/event/timing_read', [
'body' => '{"base_event":1,"timing_point":1,"bib":"string","sign_up":1,"read_time_ms":1}',
'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://your-instance.iw-erp.de/api/event/timing_read"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
Content = new StringContent("{\"base_event\":1,\"timing_point\":1,\"bib\":\"string\",\"sign_up\":1,\"read_time_ms\":1}")
{
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, "{\"base_event\":1,\"timing_point\":1,\"bib\":\"string\",\"sign_up\":1,\"read_time_ms\":1}");
Request request = new Request.Builder()
.url("https://your-instance.iw-erp.de/api/event/timing_read")
.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://your-instance.iw-erp.de/api/event/timing_read"
payload := strings.NewReader("{\"base_event\":1,\"timing_point\":1,\"bib\":\"string\",\"sign_up\":1,\"read_time_ms\":1}")
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 with the iw_erp_api package
import 'package:iw_erp_api/clients/event_timing_read_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'your-instance.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await EventTimingReadController.post(baseEventId: 42);
if (result.success) {
print(result.data);
}Several reads at once, e.g. from an app or an external timing system.
POST/api/event/timing_read/batch
Request body application/json
base_eventintegerreadsarray<object>
Responses
200{results: [ReadResult]}
curl --request POST \
--url https://your-instance.iw-erp.de/api/event/timing_read/batch \
--header 'content-type: application/json' \
--header 'x-iw-jwt-token: <TOKEN>' \
--data '
{
"base_event": 1,
"reads": [
{}
]
}
'const options = {
method: 'POST',
headers: {'x-iw-jwt-token': '<TOKEN>', 'content-type': 'application/json'},
body: JSON.stringify({base_event: 1, reads: [{}]})
};
fetch('https://your-instance.iw-erp.de/api/event/timing_read/batch', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://your-instance.iw-erp.de/api/event/timing_read/batch"
payload = {
"base_event": 1,
"reads": [{}]
}
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://your-instance.iw-erp.de/api/event/timing_read/batch', [
'body' => '{"base_event":1,"reads":[{}]}',
'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://your-instance.iw-erp.de/api/event/timing_read/batch"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
Content = new StringContent("{\"base_event\":1,\"reads\":[{}]}")
{
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, "{\"base_event\":1,\"reads\":[{}]}");
Request request = new Request.Builder()
.url("https://your-instance.iw-erp.de/api/event/timing_read/batch")
.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://your-instance.iw-erp.de/api/event/timing_read/batch"
payload := strings.NewReader("{\"base_event\":1,\"reads\":[{}]}")
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 with the iw_erp_api package
import 'package:iw_erp_api/clients/event_timing_read_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'your-instance.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await EventTimingReadController.batch(42, List<EventTimingReadInput>.fromJson({
"base_event": 1,
"reads": [
{}
]
}));
if (result.success) {
print(result.data);
}Correction of a read: status (e.g. IGNORED), assigned sign up or timing point.
PUT/api/event/timing_read/{identifier}
Path parameters
identifierrequiredstring |
Request body application/json
statusstringsign_upintegertiming_pointinteger
Responses
200The updated readEventTimingRead
Show fields (19)
base_event_idintegertiming_point_idintegersign_up_idintegerbib_labelstringnamestringdevice_idintegerread_time_msintegerUnix time in milliseconds (device clock corrected by its offset).
idintegerPrimary key of the timing read. Internal ID.
raw_bibstringBib number as read by the device.
raw_chipstringChip ID as read by the device.
read_timestring (date-time)Time of the read.
sourcestringSource of the read, for example device or manual entry.
external_idstringId of the read at its source (device sequence number, CSV row), used for idempotency.
statusstringStatus of the read, for example matched or unknown.
latitudenumber (float)Latitude of the read in degrees, if known.
longitudenumber (float)Longitude of the read in degrees, if known.
accuracynumber (float)Accuracy of the position in meters.
notestringNote on the read.
createdstring (date-time)Time the read was stored.
curl --request PUT \
--url https://your-instance.iw-erp.de/api/event/timing_read/42 \
--header 'content-type: application/json' \
--header 'x-iw-jwt-token: <TOKEN>' \
--data '
{
"status": "string",
"sign_up": 1,
"timing_point": 1
}
'const options = {
method: 'PUT',
headers: {'x-iw-jwt-token': '<TOKEN>', 'content-type': 'application/json'},
body: JSON.stringify({status: 'string', sign_up: 1, timing_point: 1})
};
fetch('https://your-instance.iw-erp.de/api/event/timing_read/42', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://your-instance.iw-erp.de/api/event/timing_read/42"
payload = {
"status": "string",
"sign_up": 1,
"timing_point": 1
}
headers = {
"x-iw-jwt-token": "<TOKEN>",
"content-type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('PUT', 'https://your-instance.iw-erp.de/api/event/timing_read/42', [
'body' => '{"status":"string","sign_up":1,"timing_point":1}',
'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.Put,
RequestUri = new Uri("https://your-instance.iw-erp.de/api/event/timing_read/42"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
Content = new StringContent("{\"status\":\"string\",\"sign_up\":1,\"timing_point\":1}")
{
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, "{\"status\":\"string\",\"sign_up\":1,\"timing_point\":1}");
Request request = new Request.Builder()
.url("https://your-instance.iw-erp.de/api/event/timing_read/42")
.put(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://your-instance.iw-erp.de/api/event/timing_read/42"
payload := strings.NewReader("{\"status\":\"string\",\"sign_up\":1,\"timing_point\":1}")
req, _ := http.NewRequest("PUT", 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 with the iw_erp_api package
import 'package:iw_erp_api/clients/event_timing_read_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'your-instance.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await EventTimingReadController.put(42);
if (result.success) {
print(result.data);
}{
"name": "Beispiel",
"id": 42,
"base_event_id": 42,
"timing_point_id": 42,
"sign_up_id": 42,
"bib_label": "string",
"device_id": 42,
"read_time_ms": 1,
"raw_bib": "string",
"raw_chip": "string"
}Correction of a read: status (e.g. IGNORED), assigned sign up or timing point.
PATCH/api/event/timing_read/{identifier}
Path parameters
identifierrequiredstring |
Request body application/json
statusstringsign_upintegertiming_pointinteger
Responses
200The updated readEventTimingRead
Show fields (19)
base_event_idintegertiming_point_idintegersign_up_idintegerbib_labelstringnamestringdevice_idintegerread_time_msintegerUnix time in milliseconds (device clock corrected by its offset).
idintegerPrimary key of the timing read. Internal ID.
raw_bibstringBib number as read by the device.
raw_chipstringChip ID as read by the device.
read_timestring (date-time)Time of the read.
sourcestringSource of the read, for example device or manual entry.
external_idstringId of the read at its source (device sequence number, CSV row), used for idempotency.
statusstringStatus of the read, for example matched or unknown.
latitudenumber (float)Latitude of the read in degrees, if known.
longitudenumber (float)Longitude of the read in degrees, if known.
accuracynumber (float)Accuracy of the position in meters.
notestringNote on the read.
createdstring (date-time)Time the read was stored.
curl --request PATCH \
--url https://your-instance.iw-erp.de/api/event/timing_read/42 \
--header 'content-type: application/json' \
--header 'x-iw-jwt-token: <TOKEN>' \
--data '
{
"status": "string",
"sign_up": 1,
"timing_point": 1
}
'const options = {
method: 'PATCH',
headers: {'x-iw-jwt-token': '<TOKEN>', 'content-type': 'application/json'},
body: JSON.stringify({status: 'string', sign_up: 1, timing_point: 1})
};
fetch('https://your-instance.iw-erp.de/api/event/timing_read/42', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://your-instance.iw-erp.de/api/event/timing_read/42"
payload = {
"status": "string",
"sign_up": 1,
"timing_point": 1
}
headers = {
"x-iw-jwt-token": "<TOKEN>",
"content-type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('PATCH', 'https://your-instance.iw-erp.de/api/event/timing_read/42', [
'body' => '{"status":"string","sign_up":1,"timing_point":1}',
'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.Patch,
RequestUri = new Uri("https://your-instance.iw-erp.de/api/event/timing_read/42"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
Content = new StringContent("{\"status\":\"string\",\"sign_up\":1,\"timing_point\":1}")
{
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, "{\"status\":\"string\",\"sign_up\":1,\"timing_point\":1}");
Request request = new Request.Builder()
.url("https://your-instance.iw-erp.de/api/event/timing_read/42")
.patch(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://your-instance.iw-erp.de/api/event/timing_read/42"
payload := strings.NewReader("{\"status\":\"string\",\"sign_up\":1,\"timing_point\":1}")
req, _ := http.NewRequest("PATCH", 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 with package:http (no controller in the iw_erp_api package)
import 'dart:convert';
import 'package:http/http.dart' as http;
final response = await http.patch(
Uri.parse('https://your-instance.iw-erp.de/api/event/timing_read/42'),
headers: {'x-iw-jwt-token': '<TOKEN>', 'content-type': 'application/json'},
body: jsonEncode({
"status": "string",
"sign_up": 1,
"timing_point": 1
}),
);
print(response.body);{
"name": "Beispiel",
"id": 42,
"base_event_id": 42,
"timing_point_id": 42,
"sign_up_id": 42,
"bib_label": "string",
"device_id": 42,
"read_time_ms": 1,
"raw_bib": "string",
"raw_chip": "string"
}CSV import (multipart field "file"), see docs/event/STARTNUMMERN_ZEITMESSUNG.md.
POST/api/event/base_event/{identifier}/timing/import_csv
Path parameters
identifierrequiredstring |
Request body multipart/form-data
filestring (binary)
Responses
200{results, created, duplicates, unassigned, errors}
curl --request POST \
--url https://your-instance.iw-erp.de/api/event/base_event/42/timing/import_csv \
--header 'content-type: multipart/form-data' \
--header 'x-iw-jwt-token: <TOKEN>' \
--form file='@datei.pdf'const form = new FormData();
form.append('file', 'datei.pdf');
const options = {method: 'POST', headers: {'x-iw-jwt-token': '<TOKEN>'}};
options.body = form;
fetch('https://your-instance.iw-erp.de/api/event/base_event/42/timing/import_csv', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://your-instance.iw-erp.de/api/event/base_event/42/timing/import_csv"
files = { "file": ("datei.pdf", open("datei.pdf", "rb"), "application/pdf") }
headers = {"x-iw-jwt-token": "<TOKEN>"}
response = requests.post(url, files=files, headers=headers)
print(response.text)<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('POST', 'https://your-instance.iw-erp.de/api/event/base_event/42/timing/import_csv', [
'multipart' => [
[
'name' => 'file',
'filename' => 'datei.pdf',
'contents' => null,
'headers' => [
'Content-Type' => 'application/pdf'
]
]
]
'headers' => [
'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://your-instance.iw-erp.de/api/event/base_event/42/timing/import_csv"),
Headers =
{
{ "x-iw-jwt-token", "<TOKEN>" },
},
Content = new MultipartFormDataContent
{
new StringContent("")
{
Headers =
{
ContentType = new MediaTypeHeaderValue("application/pdf"),
ContentDisposition = new ContentDispositionHeaderValue("form-data")
{
Name = "file",
FileName = "datei.pdf",
}
}
},
},
};
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("multipart/form-data; boundary=---011000010111000001101001");
RequestBody body = RequestBody.create(mediaType, "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"datei.pdf\"\r\nContent-Type: application/pdf\r\n\r\n\r\n-----011000010111000001101001--");
Request request = new Request.Builder()
.url("https://your-instance.iw-erp.de/api/event/base_event/42/timing/import_csv")
.post(body)
.addHeader("x-iw-jwt-token", "<TOKEN>")
.build();
Response response = client.newCall(request).execute();package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://your-instance.iw-erp.de/api/event/base_event/42/timing/import_csv"
payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"datei.pdf\"\r\nContent-Type: application/pdf\r\n\r\n\r\n-----011000010111000001101001--")
req, _ := http.NewRequest("POST", url, payload)
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 with the iw_erp_api package
import 'package:iw_erp_api/clients/event_timing_read_controller.dart';
import 'package:iw_erp_api/logic/iw_api_state.dart';
IwApiState().host = 'your-instance.iw-erp.de';
IwApiState().currentJwtApiToken = '<TOKEN>';
final result = await EventTimingReadController.importCsv(42, [42], '…');
if (result.success) {
print(result.data);
}