Mark invoice as seen
Information
This API allow you to flag given invoice as seen
This endpoint is
synchronous
The role
user
is needed in order to use this endpointEndpoints
PUT/v1/invoice/status/{statusId}/markAsSeen
Path parameters
statusIdstring (uuid) - Required
Request
PUT /v1/invoice/:invoiceId/markAsSeen
- bash
- javascript
- .NET
curl -X 'PUT' https://api.ppd.iopole.fr//v1/invoice/9ca2d4fa-0708-4cf5-85ca-cb2cf2eced52/markAsSeen'
-H 'accept: */*'
-H 'Authorization: ${token}'
const got = require('got');
const token = 'your_token_here';
const invoiceId = '9ca2d4fa-0708-4cf5-85ca-cb2cf2eced52';
(async () => {
try {
const response = await got.put(`https://api.ppd.iopole.fr//v1/invoice/${invoiceId}/markAsSeen`, {
headers: {
'accept': '*/*',
'Authorization': Bearer `${token}`,
},
responseType: 'json',
});
console.log(response.body);
} catch (error) {
console.error(error.response.body);
}
})();
using System;
using System.Net.Http;
using System.Threading.Tasks;
class Program
{
static async Task Main(string[] args)
{
var token = "your_token_here";
var invoiceId = "9ca2d4fa-0708-4cf5-85ca-cb2cf2eced52";
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("accept", "*/*");
client.DefaultRequestHeaders.Add("Authorization", {token});
try
{
var response = await client.PutAsync("https://api.ppd.iopole.fr//v1/invoice/{invoiceId}/markAsSeen", null);
response.EnsureSuccessStatusCode();
var responseString = await response.Content.ReadAsStringAsync();
Console.WriteLine(responseString);
}
catch (HttpRequestException ex)
{
Console.WriteLine("Request error: {ex.Message}");
}
}
}
Response
Status: 204
Description: No content
Status: 401
Description: Unauthorized - Authentication is required and has failed or has not yet been provided.
Status: 403
Description: Forbidden - The server understood the request, but it refuses to authorize it. Note: This endpoint requires an admin account.