MENU navbar-image

Introduction

This documentation aims to provide all the information you need to work with our API.

Base URL

https://demo.idir.intelekt.net.pl

Authenticating requests

This API is authenticated by sending an Authorization header with the value "Bearer {YOUR_ACCESS_TOKEN}" or by sending cookie session credentials with Referer/Origin header from stateful domain.

All authenticated endpoints are marked with a requires authentication badge in the documentation below.

You can retrieve your token by visiting tokens tab in your profile and clicking Create API token or sending authentication request via API.

Authenticated user

Routes:

/routes/vendor/icore/api/user.php
/routes/vendor/idir/api/user.php

Controller:

N1ebieski\ICore\Http\Controllers\Api\Auth\UserController
N1ebieski\IDir\Http\Controllers\Api\Auth\UserController

Show user

requires authentication

Show authenticated User resource

Example request:
curl --request GET \
    --get "https://demo.idir.intelekt.net.pl/api/user" \
    --header "Authorization: Bearer {YOUR_ACCESS_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/user"
);

const headers = {
    "Authorization": "Bearer {YOUR_ACCESS_TOKEN}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
    'https://demo.idir.intelekt.net.pl/api/user',
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_ACCESS_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/user'
headers = {
  'Authorization': 'Bearer {YOUR_ACCESS_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (200):


{
    "data": {
        "id": 12250,
        "name": "Dr. Nasir Windler",
        "status": {
            "value": 1,
            "label": "active"
        },
        "created_at": "2022-03-18T16:03:02.000000Z",
        "updated_at": "2022-03-18T16:03:02.000000Z",
        "roles": [
            {
                "id": 3,
                "name": "user",
                "created_at": "2021-01-06T16:58:51.000000Z",
                "updated_at": "2021-01-06T16:58:51.000000Z"
            }
        ]
    }
}
 

Request      

GET api/user

Response

Response Fields

id  integer  

name  string  

ip  string  

(available only for admin.users.view).

email  string  

(available only for admin.users.view or owner).

status  object  

Contains int value and string label

marketing  object  

Email marketing consent, contains int value and string label (available only for admin.users.view or owner).

created_at  string  

updated_at  string  

roles  object[]  

Contains relationships Roles.

socialites  object[]  

Contains relationships Socialites (available only for admin.users.view or owner).

Index of user's dirs

requires authentication

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/user/dirs" \
    --header "Authorization: Bearer {YOUR_ACCESS_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"page\": 1,
    \"filter\": {
        \"except\": [],
        \"search\": \"\",
        \"status\": \"\",
        \"group\": \"\",
        \"orderby\": \"\",
        \"paginate\": \"\"
    }
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/user/dirs"
);

const headers = {
    "Authorization": "Bearer {YOUR_ACCESS_TOKEN}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": "",
        "group": "",
        "orderby": "",
        "paginate": ""
    }
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/user/dirs',
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_ACCESS_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'page' => 1,
            'filter' => [
                'except' => [],
                'search' => '',
                'status' => '',
                'group' => '',
                'orderby' => '',
                'paginate' => '',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/user/dirs'
payload = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": "",
        "group": "",
        "orderby": "",
        "paginate": ""
    }
}
headers = {
  'Authorization': 'Bearer {YOUR_ACCESS_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (200):


{
    "data": [
        {
            "id": 13391,
            "slug": "culpa-aut",
            "title": "Culpa aut.",
            "url": "http://wolf.com",
            "short_content": "Quia voluptatem velit pariatur eos. Est tempora omnis amet sint laborum accusantium. Natus esse rerum culpa et praesentium culpa accusamus. Aut totam consequatur ut aliquam nisi quibusdam et. Inventore nam alias magni consectetur. Dolore laudantium i",
            "content": "Quia voluptatem velit pariatur eos. Est tempora omnis amet sint laborum accusantium. Natus esse rerum culpa et praesentium culpa accusamus. Aut totam consequatur ut aliquam nisi quibusdam et. Inventore nam alias magni consectetur. Dolore laudantium in et dignissimos iusto.",
            "content_html": "Quia voluptatem velit pariatur eos. Est tempora omnis amet sint laborum accusantium. Natus esse rerum culpa et praesentium culpa accusamus. Aut totam consequatur ut aliquam nisi quibusdam et. Inventore nam alias magni consectetur. Dolore laudantium in et dignissimos iusto.",
            "less_content_html": "Quia voluptatem velit pariatur eos. Est tempora omnis amet sint laborum accusantium. Natus esse rerum culpa et praesentium culpa accusamus. Aut totam consequatur ut aliquam nisi quibusdam et. Inventore nam alias magni consectetur. Dolore laudantium i... <a href=\"https://demo.idir.intelekt.net.pl/dirs/culpa-aut\">show more &raquo</a>",
            "thumbnail_url": "https://idir.test:8443/thumbnails?url=eyJpdiI6IndNcndydXNyenV1ZG9wU1RXZ0x4WUE9PSIsInZhbHVlIjoiVEtKVEZ5N0VJYXlNbEhhRFpTaTVGQT09IiwibWFjIjoiYzgzZWNjNjZiOThkOTcwY2U5ZjUzYzgxZDg1MzZlNjQyYjRmNmY0NzEyN2YzOTY4NDJmMDhmYjY4NzYwNDkxNiJ9",
            "sum_rating": "0.00",
            "created_at": "2022-03-18T16:02:58.000000Z",
            "updated_at": "2022-03-18T16:02:58.000000Z",
            "categories": [
                {
                    "id": 2524,
                    "name": "Laborum",
                    "slug": "laborum-3",
                    "icon": null,
                    "status": {
                        "value": 1,
                        "label": "active"
                    },
                    "real_depth": 0,
                    "created_at": "2022-03-18T16:02:58.000000Z",
                    "updated_at": "2022-03-18T16:02:58.000000Z"
                }
            ],
            "links": []
        },
        {
            "id": 13392,
            "slug": "eveniet-veritatis-in",
            "title": "Eveniet veritatis in.",
            "url": "http://www.pagac.org",
            "short_content": "Suscipit maiores cumque dolore. Consequatur natus quod sunt et. Aspernatur libero ut tempore alias saepe voluptas aut. Accusamus voluptatibus doloremque sit. Ullam illum voluptatum eum.",
            "content": "Suscipit maiores cumque dolore. Consequatur natus quod sunt et. Aspernatur libero ut tempore alias saepe voluptas aut. Accusamus voluptatibus doloremque sit. Ullam illum voluptatum eum.",
            "content_html": "Suscipit maiores cumque dolore. Consequatur natus quod sunt et. Aspernatur libero ut tempore alias saepe voluptas aut. Accusamus voluptatibus doloremque sit. Ullam illum voluptatum eum.",
            "less_content_html": "Suscipit maiores cumque dolore. Consequatur natus quod sunt et. Aspernatur libero ut tempore alias saepe voluptas aut. Accusamus voluptatibus doloremque sit. Ullam illum voluptatum eum.... <a href=\"https://demo.idir.intelekt.net.pl/dirs/eveniet-veritatis-in\">show more &raquo</a>",
            "thumbnail_url": "https://idir.test:8443/thumbnails?url=eyJpdiI6ImV1R0FqcFZCTFVZcUNnZkl2dTVlVlE9PSIsInZhbHVlIjoiMmhZUFwvcjBCOEJcL0pKWm51d1phS0NVcGFVZXd1RDRMQlhXemtSZFBmZ0d3PSIsIm1hYyI6IjE2ZmIzN2QzZGQ5MDQxNjQyMGYyNjkyODA3ZmJiZDcwN2ZkMGNmZmUxMzI2MjkxODdkYjQzYjEyZDgxNjllNGYifQ==",
            "sum_rating": "0.00",
            "created_at": "2022-03-18T16:02:58.000000Z",
            "updated_at": "2022-03-18T16:02:58.000000Z",
            "categories": [
                {
                    "id": 2526,
                    "name": "Et",
                    "slug": "et-45",
                    "icon": null,
                    "status": {
                        "value": 1,
                        "label": "active"
                    },
                    "real_depth": 0,
                    "created_at": "2022-03-18T16:02:58.000000Z",
                    "updated_at": "2022-03-18T16:02:58.000000Z"
                }
            ],
            "links": []
        }
    ]
}
 

Request      

POST api/user/dirs

GET api/user/dirs

Body Parameters

page  integer optional  

filter  object optional  

filter.except  integer[] optional  

Array containing IDs, excluding records from the list.

filter.search  string optional  

Search by keyword. Must be at least 3 characters. Must not be greater than 255 characters.

filter.status  integer optional  

Must be between 0 and 5.

filter.group  integer optional  

ID of Group relationship.

filter.orderby  string optional  

Sorting the result list. Must be one of created_at|asc, created_at|desc, updated_at|asc, updated_at|desc, title|asc, title|desc, sum_rating|desc, sum_rating|asc, click|asc, click|desc, view|asc, or view|desc.

filter.paginate  integer optional  

Number of records in the list. Must be one of 25, 50, or 100.

Response

Response Fields

id  integer  

slug  string  

title  string  

short_content  string  

A shortened version of the post without HTML formatting.

content  string  

Post without HTML formatting.

content_html  string  

Post with HTML formatting.

less_content_html  string  

Post with HTML formatting with "show more" button.

notes  string  

(available only for admin.dirs.view or owner) Additional infos for moderator.

url  string  

thumbnail_url  string  

sum_rating  string  

Average rating for an entry.

status  object  

(available only for api.dirs.view or owner)

privileged_at  string  

(available only for api.dirs.view or owner) Start date of premium time.

priveleged_to  string  

(available only for api.dirs.view or owner) End date of premium time. If null and privileged_at not null then premium time is unlimited.

created_at  string  

updated_at  string  

group  object  

(available only for api.dirs.view or owner) Contains relationship Group.

user  object  

(available only for admin.dirs.view or owner) Contains relationship User.

categories  object[]  

Contains relationship Categories.

tags  object[]  

Contains relationship Tags.

fields  object[]  

Contains relationship custom Fields.

links  object  

Contains links to resources on the website and in the administration panel.

meta  object  

Paging, filtering and sorting information.

Authentication

Routes:

/routes/vendor/icore/api/auth.php

Controllers:

N1ebieski\ICore\Http\Controllers\Api\Auth\RegisterController
N1ebieski\ICore\Http\Controllers\Api\Auth\TokenController

Token

Create access token and (optional) refresh token.

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/token" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email\": \"kontakt@demo.idir.intelekt.net.pl\",
    \"password\": \"demo1234\",
    \"remember\": true
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/token"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "email": "kontakt@demo.idir.intelekt.net.pl",
    "password": "demo1234",
    "remember": true
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/token',
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'email' => 'kontakt@demo.idir.intelekt.net.pl',
            'password' => 'demo1234',
            'remember' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/token'
payload = {
    "email": "kontakt@demo.idir.intelekt.net.pl",
    "password": "demo1234",
    "remember": true
}
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (201, success):


{
    "access_token": "1|LN8Gmqe6cRHQpPr5X5GW9wFXuqHVK09L8FSb7Ju9",
    "refresh_token": "2|hVHAhrgiBmSbyYjbVAC17wjwAJyKK8TQmhglBAtM"
}
 

Request      

POST api/token

Body Parameters

email  string optional  

password  string optional  

remember  boolean optional  

Response

Response Fields

access_token  string  

refresh_token  string  

(only if remember param was true)

Register

Create user and send email verification notification

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/register" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"N1ebieski\",
    \"email\": \"example@example.pl\",
    \"password\": \"demo1234\",
    \"password_confirmation\": \"demo1234\",
    \"privacy_agreement\": true,
    \"contact_agreement\": true,
    \"marketing_agreement\": true
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/register"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "name": "N1ebieski",
    "email": "example@example.pl",
    "password": "demo1234",
    "password_confirmation": "demo1234",
    "privacy_agreement": true,
    "contact_agreement": true,
    "marketing_agreement": true
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/register',
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'N1ebieski',
            'email' => 'example@example.pl',
            'password' => 'demo1234',
            'password_confirmation' => 'demo1234',
            'privacy_agreement' => true,
            'contact_agreement' => true,
            'marketing_agreement' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/register'
payload = {
    "name": "N1ebieski",
    "email": "example@example.pl",
    "password": "demo1234",
    "password_confirmation": "demo1234",
    "privacy_agreement": true,
    "contact_agreement": true,
    "marketing_agreement": true
}
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (200):


{
    "data": {
        "id": 12253,
        "name": "Lue Herman",
        "status": {
            "value": 1,
            "label": "active"
        },
        "created_at": "2022-03-18T16:03:04.000000Z",
        "updated_at": "2022-03-18T16:03:04.000000Z",
        "roles": [
            {
                "id": 3,
                "name": "user",
                "created_at": "2021-01-06T16:58:51.000000Z",
                "updated_at": "2021-01-06T16:58:51.000000Z"
            }
        ]
    }
}
 

Request      

POST api/register

Body Parameters

name  string  

email  string  

password  string  

password_confirmation  string  

privacy_agreement  boolean  

Acceptance of privacy policy

contact_agreement  boolean  

Acceptance of receiving e-mail system notifications

marketing_agreement  boolean optional  

Acceptance of receiving marketing information notifications

Response

Response Fields

id  integer  

name  string  

ip  string  

(available only for admin.users.view).

email  string  

(available only for admin.users.view or owner).

status  object  

Contains int value and string label

marketing  object  

Email marketing consent, contains int value and string label (available only for admin.users.view or owner).

created_at  string  

updated_at  string  

roles  object[]  

Contains relationships Roles.

socialites  object[]  

Contains relationships Socialites (available only for admin.users.view or owner).

Revoke token

requires authentication

Revoke access token and refresh token.

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/revoke" \
    --header "Authorization: Bearer {YOUR_ACCESS_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/revoke"
);

const headers = {
    "Authorization": "Bearer {YOUR_ACCESS_TOKEN}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/revoke',
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_ACCESS_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/revoke'
headers = {
  'Authorization': 'Bearer {YOUR_ACCESS_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers)
response.json()

Example response (204, success):

[Empty response]
 

Request      

POST api/revoke

Refresh token

requires authentication

Create new access token and refresh token.

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/refresh" \
    --header "Authorization: Bearer {YOUR_REFRESH_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/refresh"
);

const headers = {
    "Authorization": "Bearer {YOUR_REFRESH_TOKEN}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/refresh',
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_REFRESH_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/refresh'
headers = {
  'Authorization': 'Bearer {YOUR_REFRESH_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers)
response.json()

Example response (201, success):


{
    "access_token": "3|LN8Gmqe6cRHQpPr5X5GW9wFXuqHVK09L8FSb7Ju9",
    "refresh_token": "4|hVHAhrgiBmSbyYjbVAC17wjwAJyKK8TQmhglBAtM"
}
 

Request      

POST api/refresh

Response

Response Fields

access_token  string  

refresh_token  string  

Categories

Routes:

/routes/vendor/icore/api/categories.php
/routes/vendor/idir/api/categories.php

Controllers:

N1ebieski\ICore\Http\Controllers\Api\Category\CategoryController
N1ebieski\ICore\Http\Controllers\Api\Category\Post\CategoryController
N1ebieski\IDir\Http\Controllers\Api\Category\Dir\CategoryController

Resource:

N1ebieski\ICore\Http\Resources\Category\CategoryResource

Permissions:

Index of dir's categories

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/categories/dir/index" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"page\": 1,
    \"filter\": {
        \"except\": [],
        \"search\": \"\",
        \"status\": 1,
        \"parent\": \"\",
        \"orderby\": \"\",
        \"paginate\": \"\"
    }
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/categories/dir/index"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": 1,
        "parent": "",
        "orderby": "",
        "paginate": ""
    }
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/categories/dir/index',
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'page' => 1,
            'filter' => [
                'except' => [],
                'search' => '',
                'status' => 1,
                'parent' => '',
                'orderby' => '',
                'paginate' => '',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/categories/dir/index'
payload = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": 1,
        "parent": "",
        "orderby": "",
        "paginate": ""
    }
}
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (200):


{
    "data": [
        {
            "id": 2541,
            "name": "Molestiae laboriosam",
            "slug": "molestiae-laboriosam",
            "icon": null,
            "status": {
                "value": 1,
                "label": "active"
            },
            "real_depth": 0,
            "created_at": "2022-03-18T16:03:01.000000Z",
            "updated_at": "2022-03-18T16:03:01.000000Z"
        },
        {
            "id": 2542,
            "name": "Accusantium aut",
            "slug": "accusantium-aut",
            "icon": null,
            "status": {
                "value": 1,
                "label": "active"
            },
            "real_depth": 0,
            "created_at": "2022-03-18T16:03:01.000000Z",
            "updated_at": "2022-03-18T16:03:01.000000Z"
        }
    ]
}
 

Request      

POST api/categories/dir/index

GET api/categories/dir/index

Body Parameters

page  integer optional  

filter  object optional  

filter.except  integer[] optional  

Array containing IDs, excluding records from the list.

filter.search  string optional  

Search by keyword. Must be at least 3 characters. Must not be greater than 255 characters.

filter.status  integer optional  

Must be one of 1 or 0 (available only for admin.categories.view).

filter.parent  integer optional  

ID of category parent. If 0, shows only roots.

filter.orderby  string optional  

Sorting the result list. Must be one of created_at|asc, created_at|desc, updated_at|asc, updated_at|desc, name|asc, name|desc, position|asc, position|desc, real_depth|asc, or real_depth|desc.

filter.paginate  integer optional  

Number of records in the list. Must be one of 25, 50, or 100.

Response

Response Fields

id  integer  

name  string  

slug  string  

icon  string  

Class of icon.

status  object  

Contains int value and string label.

real_depth  integer  

Level of hierarchy.

created_at  string  

updated_at  string  

ancestors  object[]  

Contains relationship Category ancestors (parent and higher).

meta  object  

Paging, filtering and sorting information.

Index of post's categories

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/categories/post/index" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"page\": 1,
    \"filter\": {
        \"except\": [],
        \"search\": \"\",
        \"status\": 1,
        \"parent\": \"\",
        \"orderby\": \"\",
        \"paginate\": \"\"
    }
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/categories/post/index"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": 1,
        "parent": "",
        "orderby": "",
        "paginate": ""
    }
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/categories/post/index',
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'page' => 1,
            'filter' => [
                'except' => [],
                'search' => '',
                'status' => 1,
                'parent' => '',
                'orderby' => '',
                'paginate' => '',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/categories/post/index'
payload = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": 1,
        "parent": "",
        "orderby": "",
        "paginate": ""
    }
}
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (200):


{
    "data": [
        {
            "id": 2543,
            "name": "Provident in",
            "slug": "provident-in",
            "icon": null,
            "status": {
                "value": 1,
                "label": "active"
            },
            "real_depth": 0,
            "created_at": "2022-03-18T16:03:03.000000Z",
            "updated_at": "2022-03-18T16:03:03.000000Z"
        },
        {
            "id": 2544,
            "name": "Consequuntur dolore",
            "slug": "consequuntur-dolore",
            "icon": null,
            "status": {
                "value": 1,
                "label": "active"
            },
            "real_depth": 0,
            "created_at": "2022-03-18T16:03:03.000000Z",
            "updated_at": "2022-03-18T16:03:03.000000Z"
        }
    ]
}
 

Request      

POST api/categories/post/index

GET api/categories/post/index

Body Parameters

page  integer optional  

filter  object optional  

filter.except  integer[] optional  

Array containing IDs, excluding records from the list.

filter.search  string optional  

Search by keyword. Must be at least 3 characters. Must not be greater than 255 characters.

filter.status  integer optional  

Must be one of 1 or 0 (available only for admin.categories.view).

filter.parent  integer optional  

ID of category parent. If 0, shows only roots.

filter.orderby  string optional  

Sorting the result list. Must be one of created_at|asc, created_at|desc, updated_at|asc, updated_at|desc, name|asc, name|desc, position|asc, position|desc, real_depth|asc, or real_depth|desc.

filter.paginate  integer optional  

Number of records in the list. Must be one of 25, 50, or 100.

Response

Response Fields

id  integer  

name  string  

slug  string  

icon  string  

Class of icon.

status  object  

Contains int value and string label.

real_depth  integer  

Level of hierarchy.

created_at  string  

updated_at  string  

ancestors  object[]  

Contains relationship Category ancestors (parent and higher).

meta  object  

Paging, filtering and sorting information.

Index of all categories

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/categories/index" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"page\": 1,
    \"filter\": {
        \"except\": [],
        \"search\": \"\",
        \"status\": 1,
        \"parent\": \"\",
        \"orderby\": \"\",
        \"paginate\": \"\"
    }
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/categories/index"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": 1,
        "parent": "",
        "orderby": "",
        "paginate": ""
    }
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/categories/index',
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'page' => 1,
            'filter' => [
                'except' => [],
                'search' => '',
                'status' => 1,
                'parent' => '',
                'orderby' => '',
                'paginate' => '',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/categories/index'
payload = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": 1,
        "parent": "",
        "orderby": "",
        "paginate": ""
    }
}
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (200):


{
    "data": [
        {
            "id": 2545,
            "name": "Minus iste",
            "slug": "minus-iste",
            "icon": null,
            "status": {
                "value": 1,
                "label": "active"
            },
            "real_depth": 0,
            "created_at": "2022-03-18T16:03:03.000000Z",
            "updated_at": "2022-03-18T16:03:03.000000Z"
        },
        {
            "id": 2546,
            "name": "Amet quam",
            "slug": "amet-quam",
            "icon": null,
            "status": {
                "value": 1,
                "label": "active"
            },
            "real_depth": 0,
            "created_at": "2022-03-18T16:03:03.000000Z",
            "updated_at": "2022-03-18T16:03:03.000000Z"
        }
    ]
}
 

Request      

POST api/categories/index

GET api/categories/index

Body Parameters

page  integer optional  

filter  object optional  

filter.except  integer[] optional  

Array containing IDs, excluding records from the list.

filter.search  string optional  

Search by keyword. Must be at least 3 characters. Must not be greater than 255 characters.

filter.status  integer optional  

Must be one of 1 or 0 (available only for admin.categories.view).

filter.parent  integer optional  

ID of category parent. If 0, shows only roots.

filter.orderby  string optional  

Sorting the result list. Must be one of created_at|asc, created_at|desc, updated_at|asc, updated_at|desc, name|asc, name|desc, position|asc, position|desc, real_depth|asc, or real_depth|desc.

filter.paginate  integer optional  

Number of records in the list. Must be one of 25, 50, or 100.

Response

Response Fields

id  integer  

name  string  

slug  string  

icon  string  

Class of icon.

status  object  

Contains int value and string label.

real_depth  integer  

Level of hierarchy.

created_at  string  

updated_at  string  

ancestors  object[]  

Contains relationship Category ancestors (parent and higher).

meta  object  

Paging, filtering and sorting information.

Dirs

Routes:

/routes/vendor/idir/api/dirs.php

Controller:

N1ebieski\IDir\Http\Controllers\Api\Dir\DirController

Resource:

N1ebieski\IDir\Http\Resources\Dir\DirResource

Permissions:

Create dir

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/dirs/group/1" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"Lorem ipsum dolor sit amet\",
    \"tags\": [
        \"swdfb\"
    ],
    \"categories\": [
        19
    ],
    \"content_html\": \"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.\",
    \"notes\": \"\",
    \"url\": \"https:\\/\\/demo.idir.intelekt.net.pl\",
    \"email\": \"kontakt@intelekt.net.pl\",
    \"g-recaptcha-response\": \"deserunt\"
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/dirs/group/1"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "title": "Lorem ipsum dolor sit amet",
    "tags": [
        "swdfb"
    ],
    "categories": [
        19
    ],
    "content_html": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.",
    "notes": "",
    "url": "https:\/\/demo.idir.intelekt.net.pl",
    "email": "kontakt@intelekt.net.pl",
    "g-recaptcha-response": "deserunt"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/dirs/group/1',
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => 'Lorem ipsum dolor sit amet',
            'tags' => [
                'swdfb',
            ],
            'categories' => [
                19,
            ],
            'content_html' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.',
            'notes' => '',
            'url' => 'https://demo.idir.intelekt.net.pl',
            'email' => 'kontakt@intelekt.net.pl',
            'g-recaptcha-response' => 'deserunt',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/dirs/group/1'
payload = {
    "title": "Lorem ipsum dolor sit amet",
    "tags": [
        "swdfb"
    ],
    "categories": [
        19
    ],
    "content_html": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.",
    "notes": "",
    "url": "https:\/\/demo.idir.intelekt.net.pl",
    "email": "kontakt@intelekt.net.pl",
    "g-recaptcha-response": "deserunt"
}
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (201):


{
    "data": {
        "id": 13399,
        "slug": "accusamus",
        "title": "Accusamus.",
        "url": "https://kassulke.net",
        "short_content": "Corporis cupiditate et quia sit et quis iusto. Est accusantium illum qui autem minima labore. Reprehenderit ea mollitia non ut ea nesciunt repellendus. Expedita et aliquid et distinctio dolor quibusdam aut.",
        "content": "Corporis cupiditate et quia sit et quis iusto. Est accusantium illum qui autem minima labore. Reprehenderit ea mollitia non ut ea nesciunt repellendus. Expedita et aliquid et distinctio dolor quibusdam aut.",
        "content_html": "Corporis cupiditate et quia sit et quis iusto. Est accusantium illum qui autem minima labore. Reprehenderit ea mollitia non ut ea nesciunt repellendus. Expedita et aliquid et distinctio dolor quibusdam aut.",
        "less_content_html": "Corporis cupiditate et quia sit et quis iusto. Est accusantium illum qui autem minima labore. Reprehenderit ea mollitia non ut ea nesciunt repellendus. Expedita et aliquid et distinctio dolor quibusdam aut.... <a href=\"http://demo.idir.intelekt.net.pl/dirs/accusamus\">show more &raquo</a>",
        "thumbnail_url": "https://idir.test:8443/thumbnails?url=eyJpdiI6InVaQlI0bnpZb0NYRjJTSnJLVkVKR3c9PSIsInZhbHVlIjoiNGluS2t4NmlLZGI5azQwRjIxaW9oVFdMWXVsY1pJQjNhckJBRzJ4MVNJbz0iLCJtYWMiOiI1MTQ2NjY2NmRhY2Y1OWI5ZjcxYmQ0MWE4MTRhYmQxYzEyZGY5MGNjZGQ0NmExMmVmMmM2ZmZlMjA2ZjQ1YmRjIn0=",
        "sum_rating": "0.00",
        "created_at": "2022-03-18T16:03:01.000000Z",
        "updated_at": "2022-03-18T16:03:01.000000Z",
        "categories": [
            {
                "id": 2540,
                "name": "Qui",
                "slug": "qui-28",
                "icon": null,
                "status": {
                    "value": 1,
                    "label": "active"
                },
                "real_depth": 0,
                "created_at": "2022-03-18T16:03:01.000000Z",
                "updated_at": "2022-03-18T16:03:01.000000Z"
            }
        ],
        "links": []
    }
}
 

Request      

POST api/dirs/group/{group}

URL Parameters

group  integer  

The group ID.

Body Parameters

title  string  

Must be between 3 and 100 characters.

tags  string[] optional  

Must be at least 3 characters. Must not be greater than 30 characters.

categories  integer[]  

Array containing category IDs.

content_html  string  

Description. Must be between 255 and 1000 characters.

notes  string optional  

Additional information for the moderator. Must be between 3 and 255 characters.

url  string optional  

Unique website url with http/https protocol.

backlink  integer optional  

ID of the selected backlink.

backlink_url  string optional  

Url with http/https protocol to backlink.

email  string optional  

Email address, required if the user adds the entry as unauthenticated.

g-recaptcha-response  string  

Recaptcha response. Only required for free groups.

field  object[] optional  

Array containing additional form fields if the group allows it.

payment_type  string optional  

If the group requires a payment, the selected type must be defined. Must be one of transfer, code_transfer, code_sms, or paypal_express.

payment_transfer  integer optional  

ID of the selected Price if payment_type is transfer.

payment_code_sms  integer optional  

ID of the selected Price if payment_type is code_sms.

code_sms  string optional  

Received code if payment_type is code_sms.

payment_code_transfer  integer optional  

ID of the selected Price if payment_type is code_transfer.

code_transfer  string optional  

Received code if payment_type is code_transfer.

payment_paypal_express  integer optional  

ID of the selected Price if payment_type is paypal_express.

Response

Response Fields

id  integer  

slug  string  

title  string  

short_content  string  

A shortened version of the post without HTML formatting.

content  string  

Post without HTML formatting.

content_html  string  

Post with HTML formatting.

less_content_html  string  

Post with HTML formatting with "show more" button.

notes  string  

(available only for admin.dirs.view or owner) Additional infos for moderator.

url  string  

thumbnail_url  string  

sum_rating  string  

Average rating for an entry.

status  object  

(available only for api.dirs.view or owner)

privileged_at  string  

(available only for api.dirs.view or owner) Start date of premium time.

priveleged_to  string  

(available only for api.dirs.view or owner) End date of premium time. If null and privileged_at not null then premium time is unlimited.

created_at  string  

updated_at  string  

group  object  

(available only for api.dirs.view or owner) Contains relationship Group.

user  object  

(available only for admin.dirs.view or owner) Contains relationship User.

categories  object[]  

Contains relationship Categories.

tags  object[]  

Contains relationship Tags.

payment  object  

(available only for owner) Contains relationship Payment.

fields  object[]  

Contains relationship custom Fields.

links  object  

Contains links to resources on the website and in the administration panel.

Index of dirs

requires authentication

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/dirs/index" \
    --header "Authorization: Bearer {YOUR_ACCESS_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"page\": 1,
    \"filter\": {
        \"except\": [],
        \"search\": \"\",
        \"status\": 1,
        \"group\": \"\",
        \"category\": \"\",
        \"orderby\": \"\",
        \"paginate\": \"\"
    }
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/dirs/index"
);

const headers = {
    "Authorization": "Bearer {YOUR_ACCESS_TOKEN}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": 1,
        "group": "",
        "category": "",
        "orderby": "",
        "paginate": ""
    }
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/dirs/index',
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_ACCESS_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'page' => 1,
            'filter' => [
                'except' => [],
                'search' => '',
                'status' => 1,
                'group' => '',
                'category' => '',
                'orderby' => '',
                'paginate' => '',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/dirs/index'
payload = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": 1,
        "group": "",
        "category": "",
        "orderby": "",
        "paginate": ""
    }
}
headers = {
  'Authorization': 'Bearer {YOUR_ACCESS_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (200):


{
    "data": [
        {
            "id": 13397,
            "slug": "delectus-dicta-modi",
            "title": "Delectus dicta modi.",
            "url": "http://www.hand.com",
            "short_content": "Eius quia necessitatibus natus esse. Voluptate itaque iure velit incidunt. Recusandae qui vitae voluptatem et sint iusto. Libero et voluptatem autem. Id exercitationem saepe consequuntur quaerat ex. Aut esse quidem omnis rerum odio.",
            "content": "Eius quia necessitatibus natus esse. Voluptate itaque iure velit incidunt. Recusandae qui vitae voluptatem et sint iusto. Libero et voluptatem autem. Id exercitationem saepe consequuntur quaerat ex. Aut esse quidem omnis rerum odio.",
            "content_html": "Eius quia necessitatibus natus esse. Voluptate itaque iure velit incidunt. Recusandae qui vitae voluptatem et sint iusto. Libero et voluptatem autem. Id exercitationem saepe consequuntur quaerat ex. Aut esse quidem omnis rerum odio.",
            "less_content_html": "Eius quia necessitatibus natus esse. Voluptate itaque iure velit incidunt. Recusandae qui vitae voluptatem et sint iusto. Libero et voluptatem autem. Id exercitationem saepe consequuntur quaerat ex. Aut esse quidem omnis rerum odio.... <a href=\"http://demo.idir.intelekt.net.pl/dirs/delectus-dicta-modi\">show more &raquo</a>",
            "thumbnail_url": "https://idir.test:8443/thumbnails?url=eyJpdiI6InNVR01OdVp1N1Fpd0c2RzExbmhuXC9nPT0iLCJ2YWx1ZSI6Ik1oN2JCa2JRVU1FZkY1M0ZCNW0rMjJoVVR1ZnZYMVhYT2x5T294WjhGZXc9IiwibWFjIjoiMDBmMjBiYzUzZjFjMGMwMDQ4ZDIxY2JhOGFiNjIxM2Y0YzE1YmQyNjdjMmM0OGNhNzNjYjNhZTcwNzE2ZWYzMyJ9",
            "sum_rating": "0.00",
            "created_at": "2022-03-18T16:03:01.000000Z",
            "updated_at": "2022-03-18T16:03:01.000000Z",
            "categories": [
                {
                    "id": 2536,
                    "name": "Sed",
                    "slug": "sed-13",
                    "icon": null,
                    "status": {
                        "value": 1,
                        "label": "active"
                    },
                    "real_depth": 0,
                    "created_at": "2022-03-18T16:03:01.000000Z",
                    "updated_at": "2022-03-18T16:03:01.000000Z"
                }
            ],
            "links": []
        },
        {
            "id": 13398,
            "slug": "suscipit-culpa",
            "title": "Suscipit culpa.",
            "url": "https://wunsch.com",
            "short_content": "Quibusdam error unde facere id aliquam animi. Autem consectetur excepturi praesentium officiis illo vitae qui. Libero hic deserunt corporis et qui consequuntur enim. Recusandae assumenda quae expedita porro vel officia. Vel ea quasi ut in ab consequa",
            "content": "Quibusdam error unde facere id aliquam animi. Autem consectetur excepturi praesentium officiis illo vitae qui. Libero hic deserunt corporis et qui consequuntur enim. Recusandae assumenda quae expedita porro vel officia. Vel ea quasi ut in ab consequatur.",
            "content_html": "Quibusdam error unde facere id aliquam animi. Autem consectetur excepturi praesentium officiis illo vitae qui. Libero hic deserunt corporis et qui consequuntur enim. Recusandae assumenda quae expedita porro vel officia. Vel ea quasi ut in ab consequatur.",
            "less_content_html": "Quibusdam error unde facere id aliquam animi. Autem consectetur excepturi praesentium officiis illo vitae qui. Libero hic deserunt corporis et qui consequuntur enim. Recusandae assumenda quae expedita porro vel officia. Vel ea quasi ut in ab consequa... <a href=\"http://demo.idir.intelekt.net.pl/dirs/suscipit-culpa\">show more &raquo</a>",
            "thumbnail_url": "https://idir.test:8443/thumbnails?url=eyJpdiI6Ikw2VVZaM0ZzbytiNkJmNU5lcmdLUVE9PSIsInZhbHVlIjoiQ0J5aHgxTDIxNTI2a2pWSWduZk9pVnJqWTFaQWQ1Y3h6dTVUbTM5NWNxcz0iLCJtYWMiOiI3MzM5MWVmNmIxMTVlMjVmZWFmNDRhMzEwZmM3NjAzYzFlOWRjYzM0NThmM2NiYmFjZDU0ZjliNzAzZTg4NWUxIn0=",
            "sum_rating": "0.00",
            "created_at": "2022-03-18T16:03:01.000000Z",
            "updated_at": "2022-03-18T16:03:01.000000Z",
            "categories": [
                {
                    "id": 2538,
                    "name": "Et",
                    "slug": "et-46",
                    "icon": null,
                    "status": {
                        "value": 1,
                        "label": "active"
                    },
                    "real_depth": 0,
                    "created_at": "2022-03-18T16:03:01.000000Z",
                    "updated_at": "2022-03-18T16:03:01.000000Z"
                }
            ],
            "links": []
        }
    ]
}
 

Request      

POST api/dirs/index

GET api/dirs/index

Body Parameters

page  integer optional  

filter  object optional  

filter.except  integer[] optional  

Array containing IDs, excluding records from the list.

filter.search  string optional  

Search by keyword. Must be at least 3 characters. Must not be greater than 255 characters.

filter.status  integer optional  

Must be one of 1 or (available only for admin.dirs.view): 0, 2, 3, 4, 5.

filter.group  integer optional  

ID of Group relationship.

filter.category  integer optional  

ID of Category relationship.

filter.orderby  string optional  

Sorting the result list. Must be one of created_at|asc, created_at|desc, updated_at|asc, updated_at|desc, title|asc, title|desc, sum_rating|desc, sum_rating|asc, click|desc, click|asc, view|desc, or view|asc.

filter.paginate  integer optional  

Number of records in the list. Must be one of 25, 50, or 100.

filter.author  integer optional  

(available only for admin.dirs.view) ID of User relationship.

filter.report  integer optional  

(available only for admin.dirs.view) Must be one of 1 or 0.

Response

Response Fields

id  integer  

slug  string  

title  string  

short_content  string  

A shortened version of the post without HTML formatting.

content  string  

Post without HTML formatting.

content_html  string  

Post with HTML formatting.

less_content_html  string  

Post with HTML formatting with "show more" button.

notes  string  

(available only for admin.dirs.view or owner) Additional infos for moderator.

url  string  

thumbnail_url  string  

sum_rating  string  

Average rating for an entry.

status  object  

(available only for api.dirs.view or owner)

privileged_at  string  

(available only for api.dirs.view or owner) Start date of premium time.

priveleged_to  string  

(available only for api.dirs.view or owner) End date of premium time. If null and privileged_at not null then premium time is unlimited.

created_at  string  

updated_at  string  

group  object  

(available only for api.dirs.view or owner) Contains relationship Group.

user  object  

(available only for admin.dirs.view or owner) Contains relationship User.

categories  object[]  

Contains relationship Categories.

tags  object[]  

Contains relationship Tags.

fields  object[]  

Contains relationship custom Fields.

links  object  

Contains links to resources on the website and in the administration panel.

meta  object  

Paging, filtering and sorting information.

Edit dir

requires authentication

Example request:
curl --request PUT \
    "https://demo.idir.intelekt.net.pl/api/dirs//group/1" \
    --header "Authorization: Bearer {YOUR_ACCESS_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"Lorem ipsum dolor sit amet\",
    \"tags\": [
        \"mgwwtimodsbaetko\"
    ],
    \"categories\": [
        14
    ],
    \"content_html\": \"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.\",
    \"notes\": \"\",
    \"url\": \"https:\\/\\/demo.idir.intelekt.net.pl\",
    \"g-recaptcha-response\": \"laudantium\"
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/dirs//group/1"
);

const headers = {
    "Authorization": "Bearer {YOUR_ACCESS_TOKEN}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "title": "Lorem ipsum dolor sit amet",
    "tags": [
        "mgwwtimodsbaetko"
    ],
    "categories": [
        14
    ],
    "content_html": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.",
    "notes": "",
    "url": "https:\/\/demo.idir.intelekt.net.pl",
    "g-recaptcha-response": "laudantium"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->put(
    'https://demo.idir.intelekt.net.pl/api/dirs//group/1',
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_ACCESS_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => 'Lorem ipsum dolor sit amet',
            'tags' => [
                'mgwwtimodsbaetko',
            ],
            'categories' => [
                14,
            ],
            'content_html' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.',
            'notes' => '',
            'url' => 'https://demo.idir.intelekt.net.pl',
            'g-recaptcha-response' => 'laudantium',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/dirs//group/1'
payload = {
    "title": "Lorem ipsum dolor sit amet",
    "tags": [
        "mgwwtimodsbaetko"
    ],
    "categories": [
        14
    ],
    "content_html": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.",
    "notes": "",
    "url": "https:\/\/demo.idir.intelekt.net.pl",
    "g-recaptcha-response": "laudantium"
}
headers = {
  'Authorization': 'Bearer {YOUR_ACCESS_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('PUT', url, headers=headers, json=payload)
response.json()

Example response (200):


{
    "data": {
        "id": 13396,
        "slug": "necessitatibus-non",
        "title": "Necessitatibus non.",
        "url": "https://graham.com",
        "short_content": "Provident eos ea provident quos. Voluptatibus ut quis voluptate temporibus dolorum accusamus autem. Aperiam facere neque voluptatem. Dignissimos nam fugiat omnis odio. Dolorem at cupiditate sed vel.",
        "content": "Provident eos ea provident quos. Voluptatibus ut quis voluptate temporibus dolorum accusamus autem. Aperiam facere neque voluptatem. Dignissimos nam fugiat omnis odio. Dolorem at cupiditate sed vel.",
        "content_html": "Provident eos ea provident quos. Voluptatibus ut quis voluptate temporibus dolorum accusamus autem. Aperiam facere neque voluptatem. Dignissimos nam fugiat omnis odio. Dolorem at cupiditate sed vel.",
        "less_content_html": "Provident eos ea provident quos. Voluptatibus ut quis voluptate temporibus dolorum accusamus autem. Aperiam facere neque voluptatem. Dignissimos nam fugiat omnis odio. Dolorem at cupiditate sed vel.... <a href=\"http://demo.idir.intelekt.net.pl/dirs/necessitatibus-non\">show more &raquo</a>",
        "thumbnail_url": "https://idir.test:8443/thumbnails?url=eyJpdiI6InRLZWUrN3BKeFo1dTN5amV3VWVURHc9PSIsInZhbHVlIjoiNlhKS1U5eitaRWJVd3RkMHo5cjhYNGZ2V3RMWDV4VTRGNUhIcHBmMVlxUT0iLCJtYWMiOiJiZWI3MDAwNWZmZWYwMTVhY2RjMGI2MWJjZmM3ZWNhMjhmZTgwZGM0OGVkNmI2ZjZhMzM4NTRhYmJiNDFlNGRiIn0=",
        "sum_rating": "0.00",
        "created_at": "2022-03-18T16:03:01.000000Z",
        "updated_at": "2022-03-18T16:03:01.000000Z",
        "categories": [
            {
                "id": 2534,
                "name": "Consequuntur",
                "slug": "consequuntur-4",
                "icon": null,
                "status": {
                    "value": 1,
                    "label": "active"
                },
                "real_depth": 0,
                "created_at": "2022-03-18T16:03:01.000000Z",
                "updated_at": "2022-03-18T16:03:01.000000Z"
            }
        ],
        "links": []
    }
}
 

Request      

PUT api/dirs/{dir}/group/{group}

URL Parameters

dir  integer  

The dir ID.

group  integer  

The group ID. If same as current and has active premium time then no new payment is required.

Body Parameters

title  string optional  

Must be between 3 and 100 characters.

tags  string[] optional  

Must be at least 3 characters. Must not be greater than 30 characters.

categories  integer[] optional  

Array containing category IDs.

content_html  string optional  

Description. Must be between 255 and 1000 characters.

notes  string optional  

Additional information for the moderator. Must be between 3 and 255 characters.

url  string optional  

Unique website url with http/https protocol.

backlink  integer optional  

ID of the selected backlink.

backlink_url  string optional  

Url with http/https protocol to backlink.

g-recaptcha-response  string  

Recaptcha response. Only required for free groups.

field  object[] optional  

Array containing additional form fields if the group allows it.

user  integer optional  

(available only for admin.dirs.edit) ID of User author. If null is no author.

payment_type  string optional  

If the group requires a payment, the selected type must be defined. Must be one of transfer, code_transfer, code_sms, or paypal_express.

payment_transfer  integer optional  

ID of the selected Price if payment_type is transfer.

payment_code_sms  integer optional  

ID of the selected Price if payment_type is code_sms.

code_sms  string optional  

Received code if payment_type is code_sms.

payment_code_transfer  integer optional  

ID of the selected Price if payment_type is code_transfer.

code_transfer  string optional  

Received code if payment_type is code_transfer.

payment_paypal_express  integer optional  

ID of the selected Price if payment_type is paypal_express.

Response

Response Fields

id  integer  

slug  string  

title  string  

short_content  string  

A shortened version of the post without HTML formatting.

content  string  

Post without HTML formatting.

content_html  string  

Post with HTML formatting.

less_content_html  string  

Post with HTML formatting with "show more" button.

notes  string  

(available only for admin.dirs.view or owner) Additional infos for moderator.

url  string  

thumbnail_url  string  

sum_rating  string  

Average rating for an entry.

status  object  

(available only for api.dirs.view or owner)

privileged_at  string  

(available only for api.dirs.view or owner) Start date of premium time.

priveleged_to  string  

(available only for api.dirs.view or owner) End date of premium time. If null and privileged_at not null then premium time is unlimited.

created_at  string  

updated_at  string  

group  object  

(available only for api.dirs.view or owner) Contains relationship Group.

user  object  

(available only for admin.dirs.view or owner) Contains relationship User.

categories  object[]  

Contains relationship Categories.

tags  object[]  

Contains relationship Tags.

payment  object  

(available only for owner) Contains relationship Payment.

fields  object[]  

Contains relationship custom Fields.

links  object  

Contains links to resources on the website and in the administration panel.

Delete dir

requires authentication

Example request:
curl --request DELETE \
    "https://demo.idir.intelekt.net.pl/api/dirs/" \
    --header "Authorization: Bearer {YOUR_ACCESS_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/dirs/"
);

const headers = {
    "Authorization": "Bearer {YOUR_ACCESS_TOKEN}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->delete(
    'https://demo.idir.intelekt.net.pl/api/dirs/',
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_ACCESS_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/dirs/'
headers = {
  'Authorization': 'Bearer {YOUR_ACCESS_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('DELETE', url, headers=headers)
response.json()

Example response (204):

[Empty response]
 

Request      

DELETE api/dirs/{dir}

URL Parameters

dir  integer  

The dir ID.

Body Parameters

reason  string optional  

(available only for admin.dirs.delete).

Edit status dir

requires authentication

Example request:
curl --request PATCH \
    "https://demo.idir.intelekt.net.pl/api/dirs//status" \
    --header "Authorization: Bearer {YOUR_ACCESS_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"status\": 1,
    \"reason\": \"quia\"
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/dirs//status"
);

const headers = {
    "Authorization": "Bearer {YOUR_ACCESS_TOKEN}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "status": 1,
    "reason": "quia"
};

fetch(url, {
    method: "PATCH",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->patch(
    'https://demo.idir.intelekt.net.pl/api/dirs//status',
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_ACCESS_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'status' => 1,
            'reason' => 'quia',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/dirs//status'
payload = {
    "status": 1,
    "reason": "quia"
}
headers = {
  'Authorization': 'Bearer {YOUR_ACCESS_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('PATCH', url, headers=headers, json=payload)
response.json()

Example response (200):


{
    "data": {
        "id": 13395,
        "slug": "voluptatem-iste-quibusdam",
        "title": "Voluptatem iste quibusdam.",
        "url": "http://www.pollich.info",
        "short_content": "Natus et expedita nihil sunt minima voluptate voluptatem. Dolores consequatur et dolores nisi. Quaerat eaque minus placeat consequatur tenetur. Repellat temporibus mollitia porro libero perferendis quo. Quo dolorem eum rerum cupiditate.",
        "content": "Natus et expedita nihil sunt minima voluptate voluptatem. Dolores consequatur et dolores nisi. Quaerat eaque minus placeat consequatur tenetur. Repellat temporibus mollitia porro libero perferendis quo. Quo dolorem eum rerum cupiditate.",
        "content_html": "Natus et expedita nihil sunt minima voluptate voluptatem. Dolores consequatur et dolores nisi. Quaerat eaque minus placeat consequatur tenetur. Repellat temporibus mollitia porro libero perferendis quo. Quo dolorem eum rerum cupiditate.",
        "less_content_html": "Natus et expedita nihil sunt minima voluptate voluptatem. Dolores consequatur et dolores nisi. Quaerat eaque minus placeat consequatur tenetur. Repellat temporibus mollitia porro libero perferendis quo. Quo dolorem eum rerum cupiditate.... <a href=\"http://demo.idir.intelekt.net.pl/dirs/voluptatem-iste-quibusdam\">show more &raquo</a>",
        "thumbnail_url": "https://idir.test:8443/thumbnails?url=eyJpdiI6InozNzdicjhiZkJuXC9KK0ZPQ0RyVE9BPT0iLCJ2YWx1ZSI6IkVtT0FTNGpqY3FUYzJ1TVRjTExBYnRRQkMwa2Z5ZnQ3UWZqaFFIZFgrcFE9IiwibWFjIjoiZGMyMWM1YWE1ZjZjNDBjY2E0ZGRkNDgwYjU4ODA0ZGFmYTM4YTA1ZWMzZGEwMmNlMDY5MDg0MDY0NTYzMDQ2MiJ9",
        "sum_rating": "0.00",
        "created_at": "2022-03-18T16:03:00.000000Z",
        "updated_at": "2022-03-18T16:03:00.000000Z",
        "categories": [
            {
                "id": 2532,
                "name": "Ut",
                "slug": "ut-28",
                "icon": null,
                "status": {
                    "value": 1,
                    "label": "active"
                },
                "real_depth": 0,
                "created_at": "2022-03-18T16:03:00.000000Z",
                "updated_at": "2022-03-18T16:03:00.000000Z"
            }
        ],
        "links": []
    }
}
 

Request      

PATCH api/dirs/{dir}/status

URL Parameters

dir  integer  

The dir ID.

Body Parameters

status  integer  

Must be one of 1, 0, or 5.

reason  string optional  

Response

Response Fields

id  integer  

slug  string  

title  string  

short_content  string  

A shortened version of the post without HTML formatting.

content  string  

Post without HTML formatting.

content_html  string  

Post with HTML formatting.

less_content_html  string  

Post with HTML formatting with "show more" button.

notes  string  

(available only for admin.dirs.view or owner) Additional infos for moderator.

url  string  

thumbnail_url  string  

sum_rating  string  

Average rating for an entry.

status  object  

(available only for api.dirs.view or owner)

privileged_at  string  

(available only for api.dirs.view or owner) Start date of premium time.

priveleged_to  string  

(available only for api.dirs.view or owner) End date of premium time. If null and privileged_at not null then premium time is unlimited.

created_at  string  

updated_at  string  

group  object  

(available only for api.dirs.view or owner) Contains relationship Group.

user  object  

(available only for admin.dirs.view or owner) Contains relationship User.

categories  object[]  

Contains relationship Categories.

tags  object[]  

Contains relationship Tags.

payment  object  

(available only for owner) Contains relationship Payment.

fields  object[]  

Contains relationship custom Fields.

links  object  

Contains links to resources on the website and in the administration panel.

Groups

Routes:

/routes/vendor/idir/api/groups.php

Controller:

N1ebieski\IDir\Http\Controllers\Api\Group\GroupController

Resource:

N1ebieski\IDir\Http\Resources\Group\GroupResource

Index of groups

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/groups/index" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"page\": 1,
    \"filter\": {
        \"except\": [],
        \"search\": \"\",
        \"visible\": 1,
        \"orderby\": \"\",
        \"paginate\": \"\"
    }
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/groups/index"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "visible": 1,
        "orderby": "",
        "paginate": ""
    }
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/groups/index',
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'page' => 1,
            'filter' => [
                'except' => [],
                'search' => '',
                'visible' => 1,
                'orderby' => '',
                'paginate' => '',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/groups/index'
payload = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "visible": 1,
        "orderby": "",
        "paginate": ""
    }
}
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (200):


{
    "data": [
        {
            "id": 19,
            "slug": "ipsum",
            "position": 10,
            "name": "Ipsum",
            "desc": "Illo iusto quo sapiente labore sequi et voluptatem. Amet voluptate distinctio voluptatem aut non. Qui odio voluptas nulla dolor velit.",
            "border": null,
            "max_cats": 1,
            "max_models": 20,
            "max_models_daily": 7,
            "visible": {
                "value": 1,
                "label": "public"
            },
            "apply_status": {
                "value": 1,
                "label": "active immediately"
            },
            "url": {
                "value": 2,
                "label": "required"
            },
            "backlink": {
                "value": 1,
                "label": "optional"
            },
            "created_at": "2022-03-18T16:03:00.000000Z",
            "updated_at": "2022-03-18T16:03:00.000000Z",
            "alt": null,
            "privileges": [
                {
                    "id": 9,
                    "name": "additional options for editing content",
                    "created_at": "2021-01-06T16:58:51.000000Z",
                    "updated_at": "2021-01-06T16:58:51.000000Z"
                }
            ]
        },
        {
            "id": 20,
            "slug": "nostrum",
            "position": 11,
            "name": "Nostrum",
            "desc": "Tenetur commodi cumque corrupti omnis rerum explicabo. Accusamus ut sequi aspernatur non a. Rerum aut voluptatem eos et quas ullam. Laborum perferendis dignissimos deserunt id qui harum. Est officiis voluptatum quo nihil qui autem.",
            "border": null,
            "max_cats": 5,
            "max_models": null,
            "max_models_daily": 7,
            "visible": {
                "value": 1,
                "label": "public"
            },
            "apply_status": {
                "value": 0,
                "label": "pending acceptance"
            },
            "url": {
                "value": 2,
                "label": "required"
            },
            "backlink": {
                "value": 0,
                "label": "none"
            },
            "created_at": "2022-03-18T16:03:00.000000Z",
            "updated_at": "2022-03-18T16:03:00.000000Z",
            "alt": null,
            "privileges": [
                {
                    "id": 9,
                    "name": "additional options for editing content",
                    "created_at": "2021-01-06T16:58:51.000000Z",
                    "updated_at": "2021-01-06T16:58:51.000000Z"
                }
            ]
        }
    ]
}
 

Request      

POST api/groups/index

GET api/groups/index

Body Parameters

page  integer optional  

filter  object optional  

filter.except  integer[] optional  

Array containing IDs, excluding records from the list.

filter.search  string optional  

Search by keyword. Must be at least 3 characters. Must not be greater than 255 characters.

filter.visible  integer optional  

Must be one of 1 or 0 (available only for admin.groups.view).

filter.orderby  string optional  

Sorting the result list. Must be one of created_at|asc, created_at|desc, updated_at|asc, updated_at|desc, name|asc, name|desc, position|asc, or position|desc.

filter.paginate  integer optional  

Number of records in the list. Must be one of 25, 50, or 100.

Response

Response Fields

id  integer  

slug  string  

position  integer  

name  string  

desc  string  

border  string  

Class of border.

max_cats  integer  

Maximum number of categories to which the entry can be added.

max_models  integer  

Maximum number of entries that can be in the group.

max_models_daily  integer  

Daily maximum number of entries that can be in the group.

visible  integer  

Indicates whether the group is public or not.

apply_status  integer  

Entry status after adding.

url  integer  

Whether the url is require.

backlink  integer  

Whether the backlink is require.

created_at  string  

updated_at  string  

alt  object  

Contains relationship alternative Group. Informs to which group the entry will be dropped after expiry of the premium time. If null the entry will be deactivate.

privileges  object[]  

Contains relationship Privileges.

prices  object[]  

Contains relationship Prices.

fields  object[]  

Contains relationship custom Fields.

meta  object  

Paging, filtering and sorting information.

Payments

Routes:

/routes/vendor/idir/api/payments.php

Controller:

N1ebieski\IDir\Http\Controllers\Api\Payment\Dir\PaymentController

Resource:

N1ebieski\IDir\Http\Resources\Payment\PaymentResource

Show dir's payment

Example request:
curl --request GET \
    --get "https://demo.idir.intelekt.net.pl/api/payments//dir/" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/payments//dir/"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
    'https://demo.idir.intelekt.net.pl/api/payments//dir/',
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/payments//dir/'
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('GET', url, headers=headers)
response.json()

Example response (200):


{
    "data": {
        "uuid": "41eef476-8465-43df-ac35-5f2e99db2adf",
        "driver": null,
        "status": {
            "value": 2,
            "label": "pending"
        },
        "created_at": "2022-03-18T16:02:59.000000Z",
        "updated_at": "2022-03-18T16:02:59.000000Z",
        "morph": {
            "id": 13394,
            "slug": "accusantium-ut",
            "title": "Accusantium ut.",
            "url": "http://www.donnelly.com",
            "short_content": "Nobis quisquam nisi aspernatur repellendus. Harum saepe consequatur temporibus corrupti qui. Tempore quia dicta aspernatur. Impedit qui iusto fugiat dolores repellat officia aliquam.",
            "content": "Nobis quisquam nisi aspernatur repellendus. Harum saepe consequatur temporibus corrupti qui. Tempore quia dicta aspernatur. Impedit qui iusto fugiat dolores repellat officia aliquam.",
            "content_html": "Nobis quisquam nisi aspernatur repellendus. Harum saepe consequatur temporibus corrupti qui. Tempore quia dicta aspernatur. Impedit qui iusto fugiat dolores repellat officia aliquam.",
            "less_content_html": "Nobis quisquam nisi aspernatur repellendus. Harum saepe consequatur temporibus corrupti qui. Tempore quia dicta aspernatur. Impedit qui iusto fugiat dolores repellat officia aliquam.... <a href=\"http://demo.idir.intelekt.net.pl/dirs/accusantium-ut\">show more &raquo</a>",
            "thumbnail_url": "https://idir.test:8443/thumbnails?url=eyJpdiI6InYxdGdacFg0S1BUVU56aHp4ajdKcHc9PSIsInZhbHVlIjoiR1cyQytGNllaUWpGU09xUnJZMlkzXC80SHcwUDhKOHRTeW1WZ2JvbXhcLzcwPSIsIm1hYyI6IjM3Mzg5OGJjNTQzODc2NWZhMTAzY2E0NjIzMmI5ZDU0Y2VkYzJjMWY0OTBiNmE4NTYwMGRiYTY4YTQ2M2Y4OGIifQ==",
            "sum_rating": "0.00",
            "created_at": "2022-03-18T16:02:59.000000Z",
            "updated_at": "2022-03-18T16:02:59.000000Z",
            "links": []
        },
        "order": {
            "id": 20,
            "type": "transfer",
            "price": "1.30",
            "regular_price": "1.30",
            "discount_price": null,
            "discount": null,
            "qr_as_image": null,
            "days": 182,
            "created_at": "2022-03-18T16:02:59.000000Z",
            "updated_at": "2022-03-18T16:02:59.000000Z"
        }
    },
    "url": "https://paytest.cashbill.pl/pl/payment/eydJpZCI6IlRFU1RfNmV6OWZ6dXpvIiwicGMiOiIiLCJ0b2tlbiI6ImJiNjQ3ZGFhOTQ3NDU1NzM0OGRhMzhkYjEyMTE0YTI5MTA0NDhkMGUifQ--"
}
 

Request      

GET api/payments/{payment_dir_pending}/dir/{driver?}

URL Parameters

payment_dir_pending  string  

The payment UUID.

driver  string optional  

The payment driver.

Response

Response Fields

uuid  string  

driver  string  

logs  string  

(available only for admin.dirs.view).

status  object  

created_at  string  

updated_at  string  

morph  object  

Contains relationship Dir.

order  object  

Contains relationship Price.

url  string  

Link to the driver's payment page (for transfer type payment).

Posts

Routes:

/routes/vendor/icore/api/posts.php

Controller:

N1ebieski\ICore\Http\Controllers\Api\Post\PostController

Resource:

N1ebieski\ICore\Http\Resources\Post\PostResource

Permissions:

Index of posts

requires authentication

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/posts/index" \
    --header "Authorization: Bearer {YOUR_ACCESS_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"page\": 1,
    \"filter\": {
        \"except\": [],
        \"search\": \"\",
        \"status\": 1,
        \"category\": \"\",
        \"orderby\": \"\",
        \"paginate\": \"\"
    }
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/posts/index"
);

const headers = {
    "Authorization": "Bearer {YOUR_ACCESS_TOKEN}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": 1,
        "category": "",
        "orderby": "",
        "paginate": ""
    }
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/posts/index',
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_ACCESS_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'page' => 1,
            'filter' => [
                'except' => [],
                'search' => '',
                'status' => 1,
                'category' => '',
                'orderby' => '',
                'paginate' => '',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/posts/index'
payload = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": 1,
        "category": "",
        "orderby": "",
        "paginate": ""
    }
}
headers = {
  'Authorization': 'Bearer {YOUR_ACCESS_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (200):


{
    "data": [
        {
            "id": 185,
            "slug": "repudiandae-est-illum-necessitatibus",
            "title": "Repudiandae est illum necessitatibus.",
            "short_content": "Non sed inventore praesentium ut facere quas animi. Occaecati necessitatibus sit aut aliquid exercitationem odio facilis sed. Necessitatibus ea natus deserunt molestiae quos. Beatae rem in voluptate architecto amet non tenetur. Iste qui tenetur ut qui amet. Aut beatae dolorem amet et explicabo vero. Corrupti quis minus excepturi fugiat. Ullam amet et architecto ipsam. Reprehenderit quae aut nostrum qui nobis exercitationem minima sit. Iure error ut omnis. Porro doloremque placeat aperiam dolorem",
            "content": "Non sed inventore praesentium ut facere quas animi. Occaecati necessitatibus sit aut aliquid exercitationem odio facilis sed. Necessitatibus ea natus deserunt molestiae quos. Beatae rem in voluptate architecto amet non tenetur. Iste qui tenetur ut qui amet. Aut beatae dolorem amet et explicabo vero. Corrupti quis minus excepturi fugiat. Ullam amet et architecto ipsam. Reprehenderit quae aut nostrum qui nobis exercitationem minima sit. Iure error ut omnis. Porro doloremque placeat aperiam dolorem. Aperiam recusandae esse sapiente iure modi assumenda saepe. Sit est ratione dolores est est quis sit. Voluptatem laudantium qui dolorem architecto eius. Quos expedita aliquid aut. Assumenda veniam ea sint iure nobis. Sunt cupiditate ut non aut porro molestiae. Et et eaque ducimus. Dolorum praesentium unde placeat. Molestiae possimus qui sed reiciendis eos voluptate sed. Ea ut adipisci rerum recusandae. Architecto atque consectetur voluptas sed et. Et ratione molestiae dolorem expedita in dicta. Dolores velit ut adipisci vel consequatur deserunt eum dolor. Totam ducimus debitis voluptatem sunt. Ad sapiente et cum. Ratione deserunt omnis eligendi ipsam vero culpa fugit. Et sed temporibus necessitatibus dolor beatae quae vel. Facere beatae ex ut maiores eos ea. Rem consequuntur doloribus totam exercitationem id est error at. Iste voluptatem modi explicabo aut. Eum tempora minima earum nisi ea. Consequatur quia consequuntur et. Nulla consequuntur sint sint id. Labore culpa aut sed vitae odit. Ad voluptatum laboriosam culpa porro natus. Nihil quia eum ad quaerat hic. Architecto sit et velit. Optio magnam nihil impedit atque harum laudantium aperiam quia. Ea fugit qui amet velit consequatur dolorem ab. Eos quia et et incidunt optio. Qui quia non eos amet. Repellat ex recusandae provident consequatur quaerat itaque odio. Veniam aut excepturi tenetur ipsam in voluptatem nulla. Blanditiis ad dolor distinctio et vero aut.",
            "content_html": "<p>Non sed inventore praesentium ut facere quas animi. Occaecati necessitatibus sit aut aliquid exercitationem odio facilis sed. Necessitatibus ea natus deserunt molestiae quos. Beatae rem in voluptate architecto amet non tenetur. Iste qui tenetur ut qui amet. Aut beatae dolorem amet et explicabo vero. Corrupti quis minus excepturi fugiat. Ullam amet et architecto ipsam. Reprehenderit quae aut nostrum qui nobis exercitationem minima sit. Iure error ut omnis. Porro doloremque placeat aperiam dolorem. Aperiam recusandae esse sapiente iure modi assumenda saepe. Sit est ratione dolores est est quis sit. Voluptatem laudantium qui dolorem architecto eius. Quos expedita aliquid aut. Assumenda veniam ea sint iure nobis. Sunt cupiditate ut non aut porro molestiae. Et et eaque ducimus. Dolorum praesentium unde placeat. Molestiae possimus qui sed reiciendis eos voluptate sed. Ea ut adipisci rerum recusandae. Architecto atque consectetur voluptas sed et. Et ratione molestiae dolorem expedita in dicta. Dolores velit ut adipisci vel consequatur deserunt eum dolor. Totam ducimus debitis voluptatem sunt. Ad sapiente et cum. Ratione deserunt omnis eligendi ipsam vero culpa fugit. Et sed temporibus necessitatibus dolor beatae quae vel. Facere beatae ex ut maiores eos ea. Rem consequuntur doloribus totam exercitationem id est error at. Iste voluptatem modi explicabo aut. Eum tempora minima earum nisi ea. Consequatur quia consequuntur et. Nulla consequuntur sint sint id. Labore culpa aut sed vitae odit. Ad voluptatum laboriosam culpa porro natus. Nihil quia eum ad quaerat hic. Architecto sit et velit. Optio magnam nihil impedit atque harum laudantium aperiam quia. Ea fugit qui amet velit consequatur dolorem ab. Eos quia et et incidunt optio. Qui quia non eos amet. Repellat ex recusandae provident consequatur quaerat itaque odio. Veniam aut excepturi tenetur ipsam in voluptatem nulla. Blanditiis ad dolor distinctio et vero aut.</p>",
            "no_more_content_html": "<p>Non sed inventore praesentium ut facere quas animi. Occaecati necessitatibus sit aut aliquid exercitationem odio facilis sed. Necessitatibus ea natus deserunt molestiae quos. Beatae rem in voluptate architecto amet non tenetur. Iste qui tenetur ut qui amet. Aut beatae dolorem amet et explicabo vero. Corrupti quis minus excepturi fugiat. Ullam amet et architecto ipsam. Reprehenderit quae aut nostrum qui nobis exercitationem minima sit. Iure error ut omnis. Porro doloremque placeat aperiam dolorem. Aperiam recusandae esse sapiente iure modi assumenda saepe. Sit est ratione dolores est est quis sit. Voluptatem laudantium qui dolorem architecto eius. Quos expedita aliquid aut. Assumenda veniam ea sint iure nobis. Sunt cupiditate ut non aut porro molestiae. Et et eaque ducimus. Dolorum praesentium unde placeat. Molestiae possimus qui sed reiciendis eos voluptate sed. Ea ut adipisci rerum recusandae. Architecto atque consectetur voluptas sed et. Et ratione molestiae dolorem expedita in dicta. Dolores velit ut adipisci vel consequatur deserunt eum dolor. Totam ducimus debitis voluptatem sunt. Ad sapiente et cum. Ratione deserunt omnis eligendi ipsam vero culpa fugit. Et sed temporibus necessitatibus dolor beatae quae vel. Facere beatae ex ut maiores eos ea. Rem consequuntur doloribus totam exercitationem id est error at. Iste voluptatem modi explicabo aut. Eum tempora minima earum nisi ea. Consequatur quia consequuntur et. Nulla consequuntur sint sint id. Labore culpa aut sed vitae odit. Ad voluptatum laboriosam culpa porro natus. Nihil quia eum ad quaerat hic. Architecto sit et velit. Optio magnam nihil impedit atque harum laudantium aperiam quia. Ea fugit qui amet velit consequatur dolorem ab. Eos quia et et incidunt optio. Qui quia non eos amet. Repellat ex recusandae provident consequatur quaerat itaque odio. Veniam aut excepturi tenetur ipsam in voluptatem nulla. Blanditiis ad dolor distinctio et vero aut.</p>",
            "less_content_html": "<p>Non sed inventore praesentium ut facere quas animi. Occaecati necessitatibus sit aut aliquid exercitationem odio facilis sed. Necessitatibus ea natus deserunt molestiae quos. Beatae rem in voluptate architecto amet non tenetur. Iste qui tenetur ut qui amet. Aut beatae dolorem amet et explicabo vero. Corrupti quis minus excepturi fugiat. Ullam amet et architecto ipsam. Reprehenderit quae aut nostrum qui nobis exercitationem minima sit. Iure error ut omnis. Porro doloremque placeat aperiam dolorem. Aperiam recusandae esse sapiente iure modi assumenda saepe. Sit est ratione dolores est est quis sit. Voluptatem laudantium qui dolorem architecto eius. Quos expedita aliquid aut. Assumenda veniam ea sint iure nobis. Sunt cupiditate ut non aut porro molestiae. Et et eaque ducimus. Dolorum praesentium unde placeat. Molestiae possimus qui sed reiciendis eos voluptate sed. Ea ut adipisci rerum recusandae. Architecto atque consectetur voluptas sed et. Et ratione molestiae dolorem expedita in dicta. Dolores velit ut adipisci vel consequatur deserunt eum dolor. Totam ducimus debitis voluptatem sunt. Ad sapiente et cum. Ratione deserunt omnis eligendi ipsam vero culpa fugit. Et sed temporibus necessitatibus dolor beatae quae vel. Facere beatae ex ut maiores eos ea. Rem consequuntur doloribus totam exercitationem id est error at. Iste voluptatem modi explicabo aut. Eum tempora minima earum nisi ea. Consequatur quia consequuntur et. Nulla consequuntur sint sint id. Labore culpa aut sed vitae odit. Ad voluptatum laboriosam culpa porro natus. Nihil quia eum ad quaerat hic. Architecto sit et velit. Optio magnam nihil impedit atque harum laudantium aperiam quia. Ea fugit qui amet velit consequatur dolorem ab. Eos quia et et incidunt optio. Qui quia non eos amet. Repellat ex recusandae provident consequatur quaerat itaque odio. Veniam aut excepturi tenetur ipsam in voluptatem nulla. Blanditiis ad dolor distinctio et vero aut.</p>",
            "seo_title": null,
            "meta_title": "Repudiandae est illum necessitatibus.",
            "seo_desc": "Nostrum in non id. Magni quibusdam minus fugiat exercitationem omnis. Dolorem vitae fuga magnam. Dolore nostrum quia sed et dignissimos similique.",
            "meta_desc": "Nostrum in non id. Magni quibusdam minus fugiat exercitationem omnis. Dolorem vitae fuga magnam. Dolore nostrum quia sed et dignissimos similique.",
            "seo_noindex": false,
            "seo_nofollow": false,
            "status": {
                "value": 1,
                "label": "active"
            },
            "comment": false,
            "first_image": null,
            "published_at": "2021-11-20T02:40:00.000000Z",
            "created_at": "2022-03-18T16:03:02.000000Z",
            "updated_at": "2022-03-18T16:03:02.000000Z",
            "user": {
                "id": 12251,
                "name": "Ava Schiller",
                "status": {
                    "value": 0,
                    "label": "inactive"
                },
                "created_at": "2022-03-18T16:03:02.000000Z",
                "updated_at": "2022-03-18T16:03:02.000000Z"
            },
            "links": {
                "web": "http://demo.idir.intelekt.net.pl/posts/repudiandae-est-illum-necessitatibus"
            }
        },
        {
            "id": 186,
            "slug": "modi-expedita-explicabo-eum-nemo-quas",
            "title": "Modi expedita explicabo eum nemo quas.",
            "short_content": "Sed repudiandae ut inventore veniam id. Beatae quo sunt tempore voluptas voluptates enim. Odio eos rerum incidunt maxime cum iure. Quaerat explicabo velit ducimus ea quo excepturi. Quia cum qui voluptas rerum eum atque fugit. Explicabo assumenda temporibus debitis eveniet qui veniam. Eius laboriosam omnis perferendis doloribus dolorem quam. Accusamus beatae ducimus assumenda est. Sed libero et hic quia. Veritatis incidunt id qui nobis earum. Labore est officiis et labore. Enim ab debitis ut volu",
            "content": "Sed repudiandae ut inventore veniam id. Beatae quo sunt tempore voluptas voluptates enim. Odio eos rerum incidunt maxime cum iure. Quaerat explicabo velit ducimus ea quo excepturi. Quia cum qui voluptas rerum eum atque fugit. Explicabo assumenda temporibus debitis eveniet qui veniam. Eius laboriosam omnis perferendis doloribus dolorem quam. Accusamus beatae ducimus assumenda est. Sed libero et hic quia. Veritatis incidunt id qui nobis earum. Labore est officiis et labore. Enim ab debitis ut voluptas voluptates pariatur distinctio. Harum molestias quis qui. Vel voluptates voluptas enim distinctio cupiditate eos. Qui asperiores consequatur eum porro. Nihil in nam officia placeat ducimus sapiente. Cum at explicabo at aspernatur. Quia totam rerum cupiditate itaque accusamus. Numquam eaque optio asperiores omnis. Quas enim illum doloribus. A culpa sunt omnis illum voluptatem est. Necessitatibus quis velit amet quibusdam. Magnam animi aliquam odit expedita expedita. Fuga laboriosam qui doloribus. Omnis pariatur occaecati a laborum amet. Inventore at suscipit blanditiis accusamus quis. Repudiandae laudantium cum temporibus porro aspernatur placeat. Tenetur aut et et id eius placeat ab expedita. Quod corrupti mollitia eligendi distinctio quod impedit asperiores. Adipisci quo qui perferendis optio. Veniam et corrupti nihil a voluptas autem architecto. Voluptatem rerum quos totam vel est et laboriosam. Veritatis voluptatem explicabo illum corporis. Nisi animi rerum maiores sint fugit aperiam mollitia sit. Rem est quia nemo asperiores eaque. Omnis officiis velit fugit vel. Voluptatem vel dolorum porro. Sequi illo delectus quia. Necessitatibus totam aliquam quis minima. A esse consequatur aperiam harum itaque sapiente. Unde qui est quasi voluptatem inventore sed voluptatibus. Soluta atque ipsam hic et. Dolor illo placeat rerum et animi temporibus. Ad esse soluta et modi et eos labore necessitatibus. Quia hic itaque nihil dolor dolores et. Dignissimos non qui nulla voluptates.",
            "content_html": "<p>Sed repudiandae ut inventore veniam id. Beatae quo sunt tempore voluptas voluptates enim. Odio eos rerum incidunt maxime cum iure. Quaerat explicabo velit ducimus ea quo excepturi. Quia cum qui voluptas rerum eum atque fugit. Explicabo assumenda temporibus debitis eveniet qui veniam. Eius laboriosam omnis perferendis doloribus dolorem quam. Accusamus beatae ducimus assumenda est. Sed libero et hic quia. Veritatis incidunt id qui nobis earum. Labore est officiis et labore. Enim ab debitis ut voluptas voluptates pariatur distinctio. Harum molestias quis qui. Vel voluptates voluptas enim distinctio cupiditate eos. Qui asperiores consequatur eum porro. Nihil in nam officia placeat ducimus sapiente. Cum at explicabo at aspernatur. Quia totam rerum cupiditate itaque accusamus. Numquam eaque optio asperiores omnis. Quas enim illum doloribus. A culpa sunt omnis illum voluptatem est. Necessitatibus quis velit amet quibusdam. Magnam animi aliquam odit expedita expedita. Fuga laboriosam qui doloribus. Omnis pariatur occaecati a laborum amet. Inventore at suscipit blanditiis accusamus quis. Repudiandae laudantium cum temporibus porro aspernatur placeat. Tenetur aut et et id eius placeat ab expedita. Quod corrupti mollitia eligendi distinctio quod impedit asperiores. Adipisci quo qui perferendis optio. Veniam et corrupti nihil a voluptas autem architecto. Voluptatem rerum quos totam vel est et laboriosam. Veritatis voluptatem explicabo illum corporis. Nisi animi rerum maiores sint fugit aperiam mollitia sit. Rem est quia nemo asperiores eaque. Omnis officiis velit fugit vel. Voluptatem vel dolorum porro. Sequi illo delectus quia. Necessitatibus totam aliquam quis minima. A esse consequatur aperiam harum itaque sapiente. Unde qui est quasi voluptatem inventore sed voluptatibus. Soluta atque ipsam hic et. Dolor illo placeat rerum et animi temporibus. Ad esse soluta et modi et eos labore necessitatibus. Quia hic itaque nihil dolor dolores et. Dignissimos non qui nulla voluptates.</p>",
            "no_more_content_html": "<p>Sed repudiandae ut inventore veniam id. Beatae quo sunt tempore voluptas voluptates enim. Odio eos rerum incidunt maxime cum iure. Quaerat explicabo velit ducimus ea quo excepturi. Quia cum qui voluptas rerum eum atque fugit. Explicabo assumenda temporibus debitis eveniet qui veniam. Eius laboriosam omnis perferendis doloribus dolorem quam. Accusamus beatae ducimus assumenda est. Sed libero et hic quia. Veritatis incidunt id qui nobis earum. Labore est officiis et labore. Enim ab debitis ut voluptas voluptates pariatur distinctio. Harum molestias quis qui. Vel voluptates voluptas enim distinctio cupiditate eos. Qui asperiores consequatur eum porro. Nihil in nam officia placeat ducimus sapiente. Cum at explicabo at aspernatur. Quia totam rerum cupiditate itaque accusamus. Numquam eaque optio asperiores omnis. Quas enim illum doloribus. A culpa sunt omnis illum voluptatem est. Necessitatibus quis velit amet quibusdam. Magnam animi aliquam odit expedita expedita. Fuga laboriosam qui doloribus. Omnis pariatur occaecati a laborum amet. Inventore at suscipit blanditiis accusamus quis. Repudiandae laudantium cum temporibus porro aspernatur placeat. Tenetur aut et et id eius placeat ab expedita. Quod corrupti mollitia eligendi distinctio quod impedit asperiores. Adipisci quo qui perferendis optio. Veniam et corrupti nihil a voluptas autem architecto. Voluptatem rerum quos totam vel est et laboriosam. Veritatis voluptatem explicabo illum corporis. Nisi animi rerum maiores sint fugit aperiam mollitia sit. Rem est quia nemo asperiores eaque. Omnis officiis velit fugit vel. Voluptatem vel dolorum porro. Sequi illo delectus quia. Necessitatibus totam aliquam quis minima. A esse consequatur aperiam harum itaque sapiente. Unde qui est quasi voluptatem inventore sed voluptatibus. Soluta atque ipsam hic et. Dolor illo placeat rerum et animi temporibus. Ad esse soluta et modi et eos labore necessitatibus. Quia hic itaque nihil dolor dolores et. Dignissimos non qui nulla voluptates.</p>",
            "less_content_html": "<p>Sed repudiandae ut inventore veniam id. Beatae quo sunt tempore voluptas voluptates enim. Odio eos rerum incidunt maxime cum iure. Quaerat explicabo velit ducimus ea quo excepturi. Quia cum qui voluptas rerum eum atque fugit. Explicabo assumenda temporibus debitis eveniet qui veniam. Eius laboriosam omnis perferendis doloribus dolorem quam. Accusamus beatae ducimus assumenda est. Sed libero et hic quia. Veritatis incidunt id qui nobis earum. Labore est officiis et labore. Enim ab debitis ut voluptas voluptates pariatur distinctio. Harum molestias quis qui. Vel voluptates voluptas enim distinctio cupiditate eos. Qui asperiores consequatur eum porro. Nihil in nam officia placeat ducimus sapiente. Cum at explicabo at aspernatur. Quia totam rerum cupiditate itaque accusamus. Numquam eaque optio asperiores omnis. Quas enim illum doloribus. A culpa sunt omnis illum voluptatem est. Necessitatibus quis velit amet quibusdam. Magnam animi aliquam odit expedita expedita. Fuga laboriosam qui doloribus. Omnis pariatur occaecati a laborum amet. Inventore at suscipit blanditiis accusamus quis. Repudiandae laudantium cum temporibus porro aspernatur placeat. Tenetur aut et et id eius placeat ab expedita. Quod corrupti mollitia eligendi distinctio quod impedit asperiores. Adipisci quo qui perferendis optio. Veniam et corrupti nihil a voluptas autem architecto. Voluptatem rerum quos totam vel est et laboriosam. Veritatis voluptatem explicabo illum corporis. Nisi animi rerum maiores sint fugit aperiam mollitia sit. Rem est quia nemo asperiores eaque. Omnis officiis velit fugit vel. Voluptatem vel dolorum porro. Sequi illo delectus quia. Necessitatibus totam aliquam quis minima. A esse consequatur aperiam harum itaque sapiente. Unde qui est quasi voluptatem inventore sed voluptatibus. Soluta atque ipsam hic et. Dolor illo placeat rerum et animi temporibus. Ad esse soluta et modi et eos labore necessitatibus. Quia hic itaque nihil dolor dolores et. Dignissimos non qui nulla voluptates.</p>",
            "seo_title": "Aliquam eius quia commodi exercitationem perspiciatis maiores.",
            "meta_title": "Aliquam eius quia commodi exercitationem perspiciatis maiores.",
            "seo_desc": "Impedit nam quod est ducimus. Excepturi id facilis quas cupiditate enim vero nulla. Eos id deleniti nam porro.",
            "meta_desc": "Impedit nam quod est ducimus. Excepturi id facilis quas cupiditate enim vero nulla. Eos id deleniti nam porro.",
            "seo_noindex": true,
            "seo_nofollow": false,
            "status": {
                "value": 1,
                "label": "active"
            },
            "comment": false,
            "first_image": null,
            "published_at": "2022-03-03T00:53:13.000000Z",
            "created_at": "2022-03-18T16:03:02.000000Z",
            "updated_at": "2022-03-18T16:03:02.000000Z",
            "user": {
                "id": 12252,
                "name": "Nathen Heidenreich V",
                "status": {
                    "value": 0,
                    "label": "inactive"
                },
                "created_at": "2022-03-18T16:03:02.000000Z",
                "updated_at": "2022-03-18T16:03:02.000000Z"
            },
            "links": {
                "web": "http://demo.idir.intelekt.net.pl/posts/modi-expedita-explicabo-eum-nemo-quas"
            }
        }
    ]
}
 

Request      

POST api/posts/index

GET api/posts/index

Body Parameters

page  integer optional  

filter  object optional  

filter.except  integer[] optional  

Array containing IDs, excluding records from the list.

filter.search  string optional  

Search by keyword. Must be at least 3 characters. Must not be greater than 255 characters.

filter.status  integer optional  

Must be one of 1 or (available only for admin.categories.view) 0, 2.

filter.category  integer optional  

ID of category contains posts.

filter.orderby  string optional  

Sorting the result list. Must be one of created_at|asc, created_at|desc, updated_at|asc, updated_at|desc, title|asc, title|desc, view|desc, or view|asc.

filter.paginate  integer optional  

Number of records in the list. Must be one of 25, 50, or 100.

Response

Response Fields

id  integer  

title  string  

slug  string  

short_content  string  

A shortened version of the post without HTML formatting.

content  string  

Post without HTML formatting.

content_html  string  

Post with HTML formatting.

no_more_content_html  string  

Post with HTML formatting without "show more" button.

less_content_html  string  

Post with HTML formatting with "show more" button.

seo_title  string  

Title for SEO.

meta_title  string  

Title for META.

seo_desc  string  

Description for SEO.

meta_desc  string  

Description for META.

seo_noindex  boolean  

Value for META.

seo_nofollow  boolean  

Value for META.

status  object  

Contains int value and string label.

comment  boolean  

Determines whether comments are allowed.

first_image  string  

Address of the first image in the post for META.

published_at  string  

created_at  string  

updated_at  string  

user  object  

Contains relationship User author.

links  object  

Contains links to resources on the website and in the administration panel.

meta  object  

Paging, filtering and sorting information.

Tags

Routes:

/routes/vendor/icore/api/tags.php

Controller:

N1ebieski\ICore\Http\Controllers\Api\Tag\TagController

Resource:

N1ebieski\ICore\Http\Resources\Tag\TagResource

Permissions:

Index of tags

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/tags/index" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"page\": 1,
    \"filter\": {
        \"except\": [],
        \"search\": \"\",
        \"orderby\": \"\",
        \"paginate\": \"\"
    }
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/tags/index"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "orderby": "",
        "paginate": ""
    }
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/tags/index',
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'page' => 1,
            'filter' => [
                'except' => [],
                'search' => '',
                'orderby' => '',
                'paginate' => '',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/tags/index'
payload = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "orderby": "",
        "paginate": ""
    }
}
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (200):


{
    "data": [
        {
            "id": 35195,
            "name": "Repudiandae",
            "slug": "repudiandae",
            "created_at": "2022-03-18T16:03:02.000000Z",
            "updated_at": "2022-03-18T16:03:02.000000Z"
        },
        {
            "id": 35196,
            "name": "Autem",
            "slug": "autem",
            "created_at": "2022-03-18T16:03:02.000000Z",
            "updated_at": "2022-03-18T16:03:02.000000Z"
        }
    ]
}
 

Request      

POST api/tags/index

GET api/tags/index

Body Parameters

page  integer optional  

filter  object optional  

filter.except  integer[] optional  

Array containing IDs, excluding records from the list.

filter.search  string optional  

Search by keyword. Must be at least 3 characters. Must not be greater than 255 characters.

filter.orderby  string optional  

Sorting the result list. Must be one of created_at|asc, created_at|desc, updated_at|asc, updated_at|desc, sum|asc, or sum|desc.

filter.paginate  integer optional  

Number of records in the list. Must be one of 25, 50, or 100.

Response

Response Fields

id  integer  

name  string  

slug  string  

created_at  string  

updated_at  string  

meta  object  

Paging, filtering and sorting information.

Tokens

Routes:

/routes/vendor/icore/api/tokens.php

Controller:

N1ebieski\ICore\Http\Controllers\Api\Token\TokenController

Permissions:

Delete token

requires authentication

Delete personal access token.

Example request:
curl --request DELETE \
    "https://demo.idir.intelekt.net.pl/api/tokens/" \
    --header "Authorization: Bearer {YOUR_ACCESS_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/tokens/"
);

const headers = {
    "Authorization": "Bearer {YOUR_ACCESS_TOKEN}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->delete(
    'https://demo.idir.intelekt.net.pl/api/tokens/',
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_ACCESS_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/tokens/'
headers = {
  'Authorization': 'Bearer {YOUR_ACCESS_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('DELETE', url, headers=headers)
response.json()

Request      

DELETE api/tokens/{token}

URL Parameters

token  integer  

The token ID.

Create token

requires authentication

Create personal access token.

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/tokens" \
    --header "Authorization: Bearer {YOUR_ACCESS_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Access\",
    \"expiration\": 7,
    \"abilities\": [
        \"api.*\"
    ]
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/tokens"
);

const headers = {
    "Authorization": "Bearer {YOUR_ACCESS_TOKEN}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "name": "Access",
    "expiration": 7,
    "abilities": [
        "api.*"
    ]
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/tokens',
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_ACCESS_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Access',
            'expiration' => 7,
            'abilities' => [
                'api.*',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/tokens'
payload = {
    "name": "Access",
    "expiration": 7,
    "abilities": [
        "api.*"
    ]
}
headers = {
  'Authorization': 'Bearer {YOUR_ACCESS_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (201, success):


{
    "access_token": "1|LN8Gmqe6cRHQpPr5X5GW9wFXuqHVK09L8FSb7Ju9"
}
 

Request      

POST api/tokens

Body Parameters

name  string  

Must be between 3 and 255 characters.

expiration  integer optional  

Token expiration time on days. If null is unlimited. Must not be greater than 1000.

abilities  string[]  

Array containing scopes. Wildcard supported. Must be one of api.*, api.users.*, api.users.view, api.categories.*, api.categories.view, api.tags.*, api.tags.view, api.posts.*, api.posts.view, api.tokens.*, api.tokens.create, api.tokens.delete, api.groups.*, api.groups.view, api.dirs.*, api.dirs.view, api.dirs.create, api.dirs.status, api.dirs.edit, or api.dirs.delete.

Response

Response Fields

access_token  string  

Users

Routes:

/routes/vendor/icore/api/users.php

Controller:

N1ebieski\ICore\Http\Controllers\Api\User\UserController

Resource:

N1ebieski\ICore\Http\Resources\User\UserResource

Permissions:

Index of users

requires authentication

Example request:
curl --request POST \
    "https://demo.idir.intelekt.net.pl/api/users/index" \
    --header "Authorization: Bearer {YOUR_ACCESS_TOKEN}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"page\": 1,
    \"filter\": {
        \"except\": [],
        \"search\": \"\",
        \"status\": 1,
        \"role\": \"\",
        \"orderby\": \"updated_at|desc\",
        \"paginate\": \"\"
    }
}"
const url = new URL(
    "https://demo.idir.intelekt.net.pl/api/users/index"
);

const headers = {
    "Authorization": "Bearer {YOUR_ACCESS_TOKEN}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": 1,
        "role": "",
        "orderby": "updated_at|desc",
        "paginate": ""
    }
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
    'https://demo.idir.intelekt.net.pl/api/users/index',
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_ACCESS_TOKEN}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'page' => 1,
            'filter' => [
                'except' => [],
                'search' => '',
                'status' => 1,
                'role' => '',
                'orderby' => 'updated_at|desc',
                'paginate' => '',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://demo.idir.intelekt.net.pl/api/users/index'
payload = {
    "page": 1,
    "filter": {
        "except": [],
        "search": "",
        "status": 1,
        "role": "",
        "orderby": "updated_at|desc",
        "paginate": ""
    }
}
headers = {
  'Authorization': 'Bearer {YOUR_ACCESS_TOKEN}',
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

response = requests.request('POST', url, headers=headers, json=payload)
response.json()

Example response (200):


{
    "data": [
        {
            "id": 12248,
            "name": "Brant Denesik",
            "status": {
                "value": 1,
                "label": "active"
            },
            "created_at": "2022-03-18T16:03:01.000000Z",
            "updated_at": "2022-03-18T16:03:01.000000Z",
            "roles": [
                {
                    "id": 3,
                    "name": "user",
                    "created_at": "2021-01-06T16:58:51.000000Z",
                    "updated_at": "2021-01-06T16:58:51.000000Z"
                }
            ]
        },
        {
            "id": 12249,
            "name": "Freida Becker III",
            "status": {
                "value": 1,
                "label": "active"
            },
            "created_at": "2022-03-18T16:03:01.000000Z",
            "updated_at": "2022-03-18T16:03:01.000000Z",
            "roles": [
                {
                    "id": 3,
                    "name": "user",
                    "created_at": "2021-01-06T16:58:51.000000Z",
                    "updated_at": "2021-01-06T16:58:51.000000Z"
                }
            ]
        }
    ]
}
 

Request      

POST api/users/index

GET api/users/index

Body Parameters

page  integer optional  

filter  object optional  

filter.except  integer[] optional  

Array containing IDs, excluding records from the list.

filter.search  string optional  

Search by keyword. Must be at least 3 characters. Must not be greater than 255 characters.

filter.status  integer optional  

Must be one of 1 or 0 (available only for admin.users.view).

filter.role  integer optional  

filter.orderby  string optional  

Sorting the result list. Must be one of created_at|asc, created_at|desc, updated_at|asc, or updated_at|desc.

filter.paginate  integer optional  

Number of records in the list. Must be one of 25, 50, or 100.

Response

Response Fields

id  integer  

name  string  

ip  string  

(available only for admin.users.view).

email  string  

(available only for admin.users.view or owner).

status  object  

Contains int value and string label

marketing  object  

Email marketing consent, contains int value and string label (available only for admin.users.view or owner).

created_at  string  

updated_at  string  

roles  object[]  

Contains relationship Roles.

socialites  object[]  

Contains relationship Socialites (available only for admin.users.view or owner).

meta  object  

Paging, filtering and sorting information.