Skip to main content

Create a POS Session

Endpoint Overview

This API endpoint provides a detailed overview of the endpoint responsible for creating a POS session within the POS module of the Juleb ERP.

Endpoint Details

  • Method: POST
  • URL: /api/v1/pos/session

Parameters

  • Path Parameters: None
  • Query Parameters: None
{
"configId": integer
}

Response

  • 201 OK: The requested resource has been created.
  • 400 Bad Request: Bad request.
  • 401 Unauthorized: Unauthorized.

Response Body

  • ID of the session that has been created.

Example

Request

const axios = require('axios');
const accountName = process.env.ACCOUNT_NAME;
const apiKey = process.env.API_KEY;
axios.post(`https://${accountName}.juleb.com/api/v1/pos/session`, {
configId: 2
}, {
headers: {
'accept': '*/*',
'Authorization': `Bearer ${apiKey}`,
'Content-Type': 'application/json'
}
})
.then(response => {
console.log(response.data);
})
.catch(error => {
console.error('Error:', error);
});

Response

1886