/api/v1/register
Requires authentication
Rate limited by the `api-global` limiter
v1
Send a bearer token, plus the X-Client-Id and X-Client-Secret headers in the Authorization header.
Kthen pong kur llogaria e token-it lejohet të regjistrojë kompani. Thirreni para hapit të
parë, që të dini nëse grupi është hapur për ju.
Grupi është i mbyllur si parazgjedhje dhe hapet me kërkesë, ose për token-in e një operatori të vetëm, ose për të gjithë operatorët e kompanisë suaj.
URL-ja e plotë: https://fature.al/api/v1/register
Përgjigjet
200 Kur llogaria juaj nuk është e autorizuar për regjistrim, përgjigja kthehet me HTTP 200 dhe `status: false`; arsyeja është te `message`.
| Field | Tipi | Përshkrimi |
|---|---|---|
| status | boolean | Gjithmonë false. Një përgjigje e suksesshme mban `status: true` dhe objektin `data` |
| message | string | Përshkrimi i gabimit. Bosh kur dështimi nuk mban ndonjë mesazh të vetin |
| errors | array | Mesazhe për t'u shfaqur te përdoruesi ose për t'u ruajtur në log. Mungon kur nuk ka gjë për të shtuar përtej `message` |
401 Unauthenticated
| Field | Tipi | Përshkrimi |
|---|---|---|
| message | string |
Shembull kërkese
curl -X GET 'https://fature.al/api/v1/register' \
-H 'Authorization: Bearer YOUR_TOKEN' \
-H 'X-Client-Id: YOUR_CLIENT_ID' \
-H 'X-Client-Secret: YOUR_CLIENT_SECRET' \
-H 'Accept: application/json'
use Illuminate\Support\Facades\Http;
$response = Http::withHeaders([
'Authorization' => 'Bearer YOUR_TOKEN',
'X-Client-Id' => 'YOUR_CLIENT_ID',
'X-Client-Secret' => 'YOUR_CLIENT_SECRET',
'Accept' => 'application/json',
])->get('https://fature.al/api/v1/register');
$data = $response->json();
use GuzzleHttp\Client;
$client = new Client();
$response = $client->request('GET', 'https://fature.al/api/v1/register', [
'headers' => [
'Authorization' => 'Bearer YOUR_TOKEN',
'X-Client-Id' => 'YOUR_CLIENT_ID',
'X-Client-Secret' => 'YOUR_CLIENT_SECRET',
'Accept' => 'application/json',
],
]);
$data = json_decode((string) $response->getBody(), true);
const response = await fetch('https://fature.al/api/v1/register', {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_TOKEN',
'X-Client-Id': 'YOUR_CLIENT_ID',
'X-Client-Secret': 'YOUR_CLIENT_SECRET',
'Accept': 'application/json'
}
});
const data = await response.json();
Shembull përgjigjeje
{
"status": false,
"message": "Te dhenat jo te sakta.",
"errors": [
"errors"
]
}
{
"message": "Unauthenticated."
}