API DOCUMENTATION

Introduction

Application Programming Interface (API) is a software/connection between two applications allowing them to exchange information.

How does that work?

Image without caption
ONe API is not much different from the others. There is a division into categories (resources) on individual micro servers. Each resource has its own functions. The function description describes the general resource and the individual endpoint.
β€œResources” refers to the information returned by an API. There are several endpoints for accessing a resource, as well as multiple methods for each endpoint.
Here is an example of a description (red color):
Image without caption

Endpoints

Endpoints indicate how to get to a specific resource, and the function indicates what interactions can be used. A single resource often has a number of related endpoints, each with its own set of pathways and methods but all delivering different information about the same thing. The endpoint also only displays the end path of a resource URL, not the base path shared by all endpoints.
Image without caption
ONe API follows the principle of placing the method next to endpoints. The method determines the possible operation that can be executed by the given function.
Image without caption

Parameters

Parameters are choices you can send to the endpoint to modify the response (for example, selecting the response format or the amount returned). Parameters can be divided into three categories: header parameters, path parameters, and query string parameters. Next to the parameters there is always a short description.
Under the name of the parameter there is always the data type of the parameter. APIs may not process the parameter correctly if it’s the wrong data type or wrong format.
  • string: An alphanumeric sequence of letters and/or numbers
  • integer: A whole number β€” can be positive or negative
  • boolean: True or false value
  • object: Key-value pairs in JSON format
  • array: A list of values
Header parameters - Parameters included in the request header, usually related to authorization.
Image without caption
Path parameters - Parameters within the path of the endpoint, before the query string.
Image without caption
Query parameters - Parameters in the query string of the endpoint.
Image without caption

Response codes

HTTP Status Code
Text
Description
400
Request is invalid
The request was invalid. It may occur for various reasons - a malformed JSON or a violated rule
500
Server error
An internal API error occurred. Don't worry, we track and verify all such errors and try to react as asap as possible.
404
Not Found
The requested resource could not be found.

Functions

GET - Retrieves the resource
POST - Creates a resource
PUT - Updates or creates within an existing resource
DELETE - Removes the resource

API general view:

Image without caption
πŸ–ΌοΈAPI detail viewSDK - Add ONe’sSDK - Add ONe’sπŸ”—Links to swagger

Microservices list:

πŸ‘€AccountπŸ›‘οΈAuthserverπŸ—‚οΈCatalogGood Issued NotesGood Issued NotesInvoicesInvoicesπŸ›’OrderpathOrdersOrdersπŸ’°PlannerπŸ’ΈPrice helperπŸ’΅PricingπŸ“RMAStockStockπŸ†Tasks
⚠️Several important and practical information for ERP

Powered by Notaku
Helpful?