MENU navbar-image

Introduction

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

<aside>As you scroll, you'll see code examples for working with the API in different programming languages in the dark area to the right (or as part of the content on mobile).
You can switch the language used with the tabs at the top right (or from the nav menu at the top left on mobile).</aside>

Authenticating requests

This API is not authenticated.

Endpoints

Display a listing of the resource.

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/shops" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/shops"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": [
        "messages.success"
    ],
    "data": {
        "shops": {
            "data": [
                {
                    "id": 119996,
                    "name": "sdr99995",
                    "code": "sbr99995",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119995,
                    "name": "sdr99994",
                    "code": "sbr99994",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119994,
                    "name": "sdr99993",
                    "code": "sbr99993",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119993,
                    "name": "sdr99992",
                    "code": "sbr99992",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119992,
                    "name": "sdr99991",
                    "code": "sbr99991",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119991,
                    "name": "sdr99990",
                    "code": "sbr99990",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119990,
                    "name": "sdr99989",
                    "code": "sbr99989",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119989,
                    "name": "sdr99988",
                    "code": "sbr99988",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119988,
                    "name": "sdr99987",
                    "code": "sbr99987",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119987,
                    "name": "sdr99986",
                    "code": "sbr99986",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119986,
                    "name": "sdr99985",
                    "code": "sbr99985",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119985,
                    "name": "sdr99984",
                    "code": "sbr99984",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119984,
                    "name": "sdr99983",
                    "code": "sbr99983",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119983,
                    "name": "sdr99982",
                    "code": "sbr99982",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                },
                {
                    "id": 119982,
                    "name": "sdr99981",
                    "code": "sbr99981",
                    "is_active": "active",
                    "type": "inside",
                    "fee": null,
                    "description": null,
                    "created_at": "2026-02-10T09:54:29.000000Z",
                    "updated_at": "2026-02-10T09:54:29.000000Z",
                    "deleted_at": null
                }
            ],
            "path": "https://viratest2.ir/api/v1/repairshops/shops",
            "per_page": 15,
            "next_cursor": "eyJpZCI6MTE5OTgyLCJfcG9pbnRzVG9OZXh0SXRlbXMiOnRydWV9",
            "next_page_url": "https://viratest2.ir/api/v1/repairshops/shops?cursor=eyJpZCI6MTE5OTgyLCJfcG9pbnRzVG9OZXh0SXRlbXMiOnRydWV9",
            "prev_cursor": null,
            "prev_page_url": null
        }
    }
}
 

Request      

GET api/v1/repairshops/shops

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Store a newly created resource in storage.

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/repairshops/shops" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"architecto\",
    \"code\": \"architecto\",
    \"type\": \"inside\",
    \"fee\": 4326.4168799999997645500116050243377685546875,
    \"description\": \"Eius et animi quos velit et.\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/shops"
);

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

let body = {
    "name": "architecto",
    "code": "architecto",
    "type": "inside",
    "fee": 4326.4168799999997645500116050243377685546875,
    "description": "Eius et animi quos velit et."
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/repairshops/shops

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

name   string     

Example: architecto

code   string     

Example: architecto

type   string  optional    

Example: inside

Must be one of:
  • inside
  • outside
fee   number  optional    

Example: 4326.41688

description   string  optional    

Example: Eius et animi quos velit et.

Show the specified resource.

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/shops/3" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/shops/3"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": [
        "messages.success"
    ],
    "data": {
        "shop": {
            "id": 3,
            "name": "architecto",
            "code": "architecto",
            "is_active": "active",
            "type": "inside",
            "fee": "4326.41688",
            "description": "Eius et animi quos velit et.",
            "created_at": "2026-02-10T09:44:07.000000Z",
            "updated_at": "2026-02-15T13:02:25.000000Z",
            "deleted_at": null
        }
    }
}
 

Request      

GET api/v1/repairshops/shops/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the shop. Example: 3

Update the specified resource in storage.

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/repairshops/shops/3" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"architecto\",
    \"code\": \"architecto\",
    \"type\": \"outside\",
    \"fee\": 4326.4168799999997645500116050243377685546875,
    \"description\": \"Eius et animi quos velit et.\",
    \"is_active\": \"inactive\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/shops/3"
);

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

let body = {
    "name": "architecto",
    "code": "architecto",
    "type": "outside",
    "fee": 4326.4168799999997645500116050243377685546875,
    "description": "Eius et animi quos velit et.",
    "is_active": "inactive"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/repairshops/shops/{id}

PATCH api/v1/repairshops/shops/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the shop. Example: 3

Body Parameters

name   string  optional    

Example: architecto

code   string  optional    

Example: architecto

type   string  optional    

Example: outside

Must be one of:
  • inside
  • outside
fee   number  optional    

Example: 4326.41688

description   string  optional    

Example: Eius et animi quos velit et.

is_active   string  optional    

Example: inactive

Must be one of:
  • active
  • inactive

Remove the specified resource from storage.

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/repairshops/shops/3" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/shops/3"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/repairshops/shops/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the shop. Example: 3

Display a listing of the resource.

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/tmCodes" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmCodes"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": [
        "messages.success"
    ],
    "data": {
        "tmCodes": {
            "data": [],
            "path": "https://viratest2.ir/api/v1/repairshops/tmCodes",
            "per_page": 15,
            "next_cursor": null,
            "next_page_url": null,
            "prev_cursor": null,
            "prev_page_url": null
        }
    }
}
 

Request      

GET api/v1/repairshops/tmCodes

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Store a newly created resource in storage.

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/repairshops/tmCodes" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"code\": \"architecto\",
    \"title\": \"architecto\",
    \"hours\": 16,
    \"amount_per_hours\": 16,
    \"max_cost\": 16,
    \"base_amount\": 16,
    \"shop_id\": 16,
    \"mechanism_group_id\": 16,
    \"is_active\": \"N\",
    \"type\": \"CM\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmCodes"
);

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

let body = {
    "code": "architecto",
    "title": "architecto",
    "hours": 16,
    "amount_per_hours": 16,
    "max_cost": 16,
    "base_amount": 16,
    "shop_id": 16,
    "mechanism_group_id": 16,
    "is_active": "N",
    "type": "CM"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/repairshops/tmCodes

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

code   string     

Example: architecto

title   string     

Example: architecto

hours   integer     

Example: 16

amount_per_hours   integer     

Example: 16

max_cost   integer     

Example: 16

base_amount   integer     

Example: 16

shop_id   integer     

Example: 16

mechanism_group_id   integer     

Example: 16

is_active   string     

Example: N

Must be one of:
  • Y
  • N
type   string     

Example: CM

Must be one of:
  • CM
  • EM
  • PM

Show the specified resource.

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/tmCodes/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmCodes/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "No query results for model [Modules\\RepairShop\\Models\\TmCode] 16"
}
 

Request      

GET api/v1/repairshops/tmCodes/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the tmCode. Example: 16

Update the specified resource in storage.

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/repairshops/tmCodes/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"code\": \"architecto\",
    \"title\": \"architecto\",
    \"hours\": 16,
    \"amount_per_hours\": 16,
    \"max_cost\": 16,
    \"base_amount\": 16,
    \"shop_id\": 16,
    \"mechanism_group_id\": 16,
    \"is_active\": \"Y\",
    \"type\": \"EM\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmCodes/16"
);

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

let body = {
    "code": "architecto",
    "title": "architecto",
    "hours": 16,
    "amount_per_hours": 16,
    "max_cost": 16,
    "base_amount": 16,
    "shop_id": 16,
    "mechanism_group_id": 16,
    "is_active": "Y",
    "type": "EM"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/repairshops/tmCodes/{id}

PATCH api/v1/repairshops/tmCodes/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the tmCode. Example: 16

Body Parameters

code   string  optional    

Example: architecto

title   string  optional    

Example: architecto

hours   integer  optional    

Example: 16

amount_per_hours   integer  optional    

Example: 16

max_cost   integer  optional    

Example: 16

base_amount   integer  optional    

Example: 16

shop_id   integer  optional    

Example: 16

mechanism_group_id   integer  optional    

Example: 16

is_active   string  optional    

Example: Y

Must be one of:
  • Y
  • N
type   string  optional    

Example: EM

Must be one of:
  • CM
  • EM
  • PM

Remove the specified resource from storage.

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/repairshops/tmCodes/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmCodes/16"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/repairshops/tmCodes/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the tmCode. Example: 16

Display a listing of the resource.

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/finalStatements" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/finalStatements"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": [
        "messages.success"
    ],
    "data": {
        "finalStatements": {
            "data": [],
            "path": "https://viratest2.ir/api/v1/repairshops/finalStatements",
            "per_page": 15,
            "next_cursor": null,
            "next_page_url": null,
            "prev_cursor": null,
            "prev_page_url": null
        }
    }
}
 

Request      

GET api/v1/repairshops/finalStatements

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Store a newly created resource in storage.

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/repairshops/finalStatements" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"b\",
    \"number\": 16,
    \"date\": \"2026-02-21T07:15:17\",
    \"creator_id\": 16,
    \"shop_id\": 16,
    \"shop_name\": \"architecto\",
    \"description\": \"Eius et animi quos velit et.\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/finalStatements"
);

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

let body = {
    "title": "b",
    "number": 16,
    "date": "2026-02-21T07:15:17",
    "creator_id": 16,
    "shop_id": 16,
    "shop_name": "architecto",
    "description": "Eius et animi quos velit et."
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/repairshops/finalStatements

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

title   string     

فیلد value نباید کمتر از 2 کاراکتر باشد. فیلد value نباید بیشتر از 50 کاراکتر باشد. Example: b

number   integer     

Example: 16

date   string     

فیلد value باید یک تاریخ معتبر باشد. Example: 2026-02-21T07:15:17

creator_id   integer     

Example: 16

shop_id   integer     

Example: 16

shop_name   string     

Example: architecto

description   string     

Example: Eius et animi quos velit et.

Show the specified resource.

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/finalStatements/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/finalStatements/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "No query results for model [Modules\\RepairShop\\Models\\FinalStatement] 16"
}
 

Request      

GET api/v1/repairshops/finalStatements/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the finalStatement. Example: 16

Update the specified resource in storage.

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/repairshops/finalStatements/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"b\",
    \"number\": 16,
    \"date\": \"2026-02-21T07:15:18\",
    \"creator_id\": 16,
    \"shop_id\": 16,
    \"shop_name\": \"architecto\",
    \"description\": \"Eius et animi quos velit et.\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/finalStatements/16"
);

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

let body = {
    "title": "b",
    "number": 16,
    "date": "2026-02-21T07:15:18",
    "creator_id": 16,
    "shop_id": 16,
    "shop_name": "architecto",
    "description": "Eius et animi quos velit et."
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/repairshops/finalStatements/{id}

PATCH api/v1/repairshops/finalStatements/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the finalStatement. Example: 16

Body Parameters

title   string  optional    

فیلد value نباید کمتر از 2 کاراکتر باشد. فیلد value نباید بیشتر از 50 کاراکتر باشد. Example: b

number   integer  optional    

Example: 16

date   string  optional    

فیلد value باید یک تاریخ معتبر باشد. Example: 2026-02-21T07:15:18

creator_id   integer  optional    

Example: 16

shop_id   integer  optional    

Example: 16

shop_name   string  optional    

Example: architecto

description   string  optional    

Example: Eius et animi quos velit et.

Remove the specified resource from storage.

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/repairshops/finalStatements/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/finalStatements/16"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/repairshops/finalStatements/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the finalStatement. Example: 16

Display a listing of the resource.

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/finalStatementsFactors" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/finalStatementsFactors"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": [
        "messages.success"
    ],
    "data": {
        "finalStatementsFactors": {
            "data": [],
            "path": "https://viratest2.ir/api/v1/repairshops/finalStatementsFactors",
            "per_page": 15,
            "next_cursor": null,
            "next_page_url": null,
            "prev_cursor": null,
            "prev_page_url": null
        }
    }
}
 

Request      

GET api/v1/repairshops/finalStatementsFactors

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Store a newly created resource in storage.

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/repairshops/finalStatementsFactors" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"bngzmiyvdljnikhwaykcmyuwpwlvqwrsitcpscqldzsnrwtujwvlxjklqppwqbewtnnoqitpxn\",
    \"number\": 16,
    \"date\": \"2026-02-21T07:15:18\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/finalStatementsFactors"
);

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

let body = {
    "name": "bngzmiyvdljnikhwaykcmyuwpwlvqwrsitcpscqldzsnrwtujwvlxjklqppwqbewtnnoqitpxn",
    "number": 16,
    "date": "2026-02-21T07:15:18"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/repairshops/finalStatementsFactors

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

name   string  optional    

فیلد value نباید کمتر از 3 کاراکتر باشد. Example: bngzmiyvdljnikhwaykcmyuwpwlvqwrsitcpscqldzsnrwtujwvlxjklqppwqbewtnnoqitpxn

number   integer  optional    

Example: 16

date   string  optional    

فیلد value باید یک تاریخ معتبر باشد. Example: 2026-02-21T07:15:18

final_statement_id   string  optional    

The id of an existing record in the final_statements table.

Show the specified resource.

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/finalStatementsFactors/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/finalStatementsFactors/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": [
        "messages.success"
    ],
    "data": {
        "finalStatementFactor": {
            "final": null
        }
    }
}
 

Request      

GET api/v1/repairshops/finalStatementsFactors/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the finalStatementsFactor. Example: 16

Update the specified resource in storage.

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/repairshops/finalStatementsFactors/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"bngzmiyvdljnikhwaykcmyuwpwlvqwrsitcpscqldzsnrwtujwvlxjklqppwqbewtnnoqitpxn\",
    \"number\": 16,
    \"date\": \"2026-02-21T07:15:18\",
    \"final_statement_id\": \"architecto\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/finalStatementsFactors/16"
);

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

let body = {
    "name": "bngzmiyvdljnikhwaykcmyuwpwlvqwrsitcpscqldzsnrwtujwvlxjklqppwqbewtnnoqitpxn",
    "number": 16,
    "date": "2026-02-21T07:15:18",
    "final_statement_id": "architecto"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/repairshops/finalStatementsFactors/{id}

PATCH api/v1/repairshops/finalStatementsFactors/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the finalStatementsFactor. Example: 16

Body Parameters

name   string     

فیلد value نباید کمتر از 3 کاراکتر باشد. Example: bngzmiyvdljnikhwaykcmyuwpwlvqwrsitcpscqldzsnrwtujwvlxjklqppwqbewtnnoqitpxn

number   integer     

Example: 16

date   string     

فیلد value باید یک تاریخ معتبر باشد. Example: 2026-02-21T07:15:18

final_statement_id   string     

The id of an existing record in the final_statements table. Example: architecto

Remove the specified resource from storage.

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/repairshops/finalStatementsFactors/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/finalStatementsFactors/16"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/repairshops/finalStatementsFactors/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the finalStatementsFactor. Example: 16

Display a listing of the resource.

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/pmGroups" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/pmGroups"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": [
        "messages.success"
    ],
    "data": {
        "pmGroups": {
            "data": [],
            "path": "https://viratest2.ir/api/v1/repairshops/pmGroups",
            "per_page": 15,
            "next_cursor": null,
            "next_page_url": null,
            "prev_cursor": null,
            "prev_page_url": null
        }
    }
}
 

Request      

GET api/v1/repairshops/pmGroups

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Store a newly created resource in storage.

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/repairshops/pmGroups" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"tm_code_id\": \"architecto\",
    \"mechanism_group_code\": \"architecto\",
    \"description\": \"Eius et animi quos velit et.\",
    \"minutes\": 16,
    \"km\": 16
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/pmGroups"
);

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

let body = {
    "tm_code_id": "architecto",
    "mechanism_group_code": "architecto",
    "description": "Eius et animi quos velit et.",
    "minutes": 16,
    "km": 16
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/repairshops/pmGroups

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

tm_code_id   string     

The id of an existing record in the tm_codes table. Example: architecto

mechanism_group_code   string     

Example: architecto

description   string  optional    

Example: Eius et animi quos velit et.

minutes   integer     

Example: 16

km   integer     

Example: 16

Show the specified resource.

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/pmGroups/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/pmGroups/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "No query results for model [Modules\\RepairShop\\Models\\PmGroup] 16"
}
 

Request      

GET api/v1/repairshops/pmGroups/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the pmGroup. Example: 16

Update the specified resource in storage.

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/repairshops/pmGroups/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"mechanism_group_code\": \"architecto\",
    \"description\": \"Eius et animi quos velit et.\",
    \"minutes\": 16,
    \"km\": 16
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/pmGroups/16"
);

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

let body = {
    "mechanism_group_code": "architecto",
    "description": "Eius et animi quos velit et.",
    "minutes": 16,
    "km": 16
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/repairshops/pmGroups/{id}

PATCH api/v1/repairshops/pmGroups/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the pmGroup. Example: 16

Body Parameters

tm_code_id   string  optional    

The id of an existing record in the tm_codes table.

mechanism_group_code   string  optional    

Example: architecto

description   string  optional    

Example: Eius et animi quos velit et.

minutes   integer  optional    

Example: 16

km   integer  optional    

Example: 16

Remove the specified resource from storage.

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/repairshops/pmGroups/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/pmGroups/16"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/repairshops/pmGroups/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the pmGroup. Example: 16

Display a listing of the resource.

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/repairmen" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/repairmen"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/repairshops/repairmen

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Store a newly created resource in storage.

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/repairshops/repairmen" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"b\",
    \"family\": \"n\",
    \"personal_code\": \"gzmiyvd\",
    \"workplace\": \"l\",
    \"contract_status\": \"completion\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/repairmen"
);

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

let body = {
    "name": "b",
    "family": "n",
    "personal_code": "gzmiyvd",
    "workplace": "l",
    "contract_status": "completion"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/repairshops/repairmen

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

name   string     

فیلد value نباید کمتر از 3 کاراکتر باشد. فیلد value نباید بیشتر از 30 کاراکتر باشد. Example: b

family   string     

فیلد value نباید کمتر از 3 کاراکتر باشد. فیلد value نباید بیشتر از 30 کاراکتر باشد. Example: n

phone   string  optional    
national_code   string  optional    
personal_code   string  optional    

فیلد value نباید کمتر از 2 کاراکتر باشد. فیلد value نباید بیشتر از 7 کاراکتر باشد. Example: gzmiyvd

workplace   string  optional    

فیلد value نباید کمتر از 3 کاراکتر باشد. فیلد value نباید بیشتر از 50 کاراکتر باشد. Example: l

contract_status   string  optional    

Example: completion

Must be one of:
  • have
  • completion
  • no_need

Show the specified resource.

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/repairmen/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/repairmen/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "No query results for model [Modules\\RepairShop\\Models\\Repairman] 16"
}
 

Request      

GET api/v1/repairshops/repairmen/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the repairman. Example: 16

Update the specified resource in storage.

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/repairshops/repairmen/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"b\",
    \"family\": \"n\",
    \"personal_code\": \"gzmiyvd\",
    \"workplace\": \"l\",
    \"contract_status\": \"have\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/repairmen/16"
);

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

let body = {
    "name": "b",
    "family": "n",
    "personal_code": "gzmiyvd",
    "workplace": "l",
    "contract_status": "have"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/repairshops/repairmen/{id}

PATCH api/v1/repairshops/repairmen/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the repairman. Example: 16

Body Parameters

name   string  optional    

فیلد value نباید کمتر از 3 کاراکتر باشد. فیلد value نباید بیشتر از 30 کاراکتر باشد. Example: b

family   string  optional    

فیلد value نباید کمتر از 3 کاراکتر باشد. فیلد value نباید بیشتر از 30 کاراکتر باشد. Example: n

phone   string  optional    
national_code   string  optional    
personal_code   string  optional    

فیلد value نباید کمتر از 2 کاراکتر باشد. فیلد value نباید بیشتر از 7 کاراکتر باشد. Example: gzmiyvd

workplace   string  optional    

فیلد value نباید کمتر از 3 کاراکتر باشد. فیلد value نباید بیشتر از 50 کاراکتر باشد. Example: l

contract_status   string  optional    

Example: have

Must be one of:
  • have
  • completion
  • no_need

Remove the specified resource from storage.

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/repairshops/repairmen/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/repairmen/16"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/repairshops/repairmen/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the repairman. Example: 16

POST api/v1/repairshops/tmRequests

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/repairshops/tmRequests" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"mechanism_id\": 16,
    \"driver_id\": 16,
    \"description\": \"Et animi quos velit et fugiat.\",
    \"type\": \"CM\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmRequests"
);

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

let body = {
    "mechanism_id": 16,
    "driver_id": 16,
    "description": "Et animi quos velit et fugiat.",
    "type": "CM"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/repairshops/tmRequests

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

mechanism_id   integer     

Example: 16

driver_id   integer     

Example: 16

description   string  optional    

فیلد value نباید بیشتر از 255 کاراکتر باشد. Example: Et animi quos velit et fugiat.

type   string  optional    

Example: CM

Must be one of:
  • PM
  • CM
  • EM

GET api/v1/repairshops/tmRequests/{id}

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/repairshops/tmRequests/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/repairshops/tmRequests/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the tmRequest. Example: 16

PUT api/v1/repairshops/tmRequests/{id}

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"infos\": [
        {
            \"id\": 16,
            \"tm_code_id\": 16,
            \"shop_id\": 16,
            \"mechanism_id\": 16,
            \"driver_id\": 16,
            \"status\": \"architecto\"
        }
    ]
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16"
);

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

let body = {
    "infos": [
        {
            "id": 16,
            "tm_code_id": 16,
            "shop_id": 16,
            "mechanism_id": 16,
            "driver_id": 16,
            "status": "architecto"
        }
    ]
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/repairshops/tmRequests/{id}

PATCH api/v1/repairshops/tmRequests/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the tmRequest. Example: 16

Body Parameters

infos   object[]  optional    
id   integer  optional    

The id of an existing record in the repairshop.tm_requests_info table. Example: 16

tm_code_id   integer     

The id of an existing record in the repairshop.tm_codes table. Example: 16

shop_id   integer  optional    

The id of an existing record in the repairshop.shops table. Example: 16

mechanism_id   integer     

The id of an existing record in the repairshop.mechanisms table. Example: 16

driver_id   integer  optional    

The id of an existing record in the repairshop.drivers table. Example: 16

status   string  optional    

Example: architecto

DELETE api/v1/repairshops/tmRequests/{id}

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/repairshops/tmRequests/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the tmRequest. Example: 16

POST api/v1/repairshops/tmRequests/storeFromWorkshop

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/repairshops/tmRequests/storeFromWorkshop" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"mechanism_id\": 16,
    \"driver_id\": 16,
    \"type\": \"EM\",
    \"infos\": [
        {
            \"tm_code_id\": \"architecto\",
            \"shop_id\": \"architecto\",
            \"description\": \"Et animi quos velit et fugiat.\",
            \"cost\": 16,
            \"tm_code_count\": 22,
            \"type_code\": \"not_accepted\"
        }
    ]
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmRequests/storeFromWorkshop"
);

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

let body = {
    "mechanism_id": 16,
    "driver_id": 16,
    "type": "EM",
    "infos": [
        {
            "tm_code_id": "architecto",
            "shop_id": "architecto",
            "description": "Et animi quos velit et fugiat.",
            "cost": 16,
            "tm_code_count": 22,
            "type_code": "not_accepted"
        }
    ]
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/repairshops/tmRequests/storeFromWorkshop

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

mechanism_id   integer     

Example: 16

driver_id   integer     

Example: 16

type   string  optional    

Example: EM

Must be one of:
  • PM
  • CM
  • EM
infos   object[]     

فیلد value نباید کمتر از 1 آیتم داشته باشد.

tm_code_id   string     

The id of an existing record in the repairshop.tm_codes table. Example: architecto

shop_id   string     

The id of an existing record in the repairshop.shops table. Example: architecto

description   string  optional    

فیلد value نباید بیشتر از 255 کاراکتر باشد. Example: Et animi quos velit et fugiat.

cost   integer  optional    

Example: 16

tm_code_count   integer  optional    

فیلد value نباید کوچکتر از 1 باشد. Example: 22

type_code   string  optional    

Example: not_accepted

Must be one of:
  • all
  • accepted
  • not_accepted

POST api/v1/repairshops/tmRequests/setTmRequestFinalStatement

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/repairshops/tmRequests/setTmRequestFinalStatement" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"final_statement_id\": \"architecto\",
    \"work_order_numbers\": [
        \"architecto\"
    ]
}"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmRequests/setTmRequestFinalStatement"
);

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

let body = {
    "final_statement_id": "architecto",
    "work_order_numbers": [
        "architecto"
    ]
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/repairshops/tmRequests/setTmRequestFinalStatement

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

final_statement_id   string     

The id of an existing record in the final_statements table. Example: architecto

work_order_numbers   string[]     

The work_order_number of an existing record in the tm_requests table.

PATCH api/v1/repairshops/tmRequests/{tmrequest_id}/reject

Example request:
curl --request PATCH \
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16/reject" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16/reject"
);

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

fetch(url, {
    method: "PATCH",
    headers,
}).then(response => response.json());

Request      

PATCH api/v1/repairshops/tmRequests/{tmrequest_id}/reject

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

tmrequest_id   integer     

The ID of the tmrequest. Example: 16

PATCH api/v1/repairshops/tmRequests/{tmrequest_id}/toWaiting

Example request:
curl --request PATCH \
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16/toWaiting" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16/toWaiting"
);

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

fetch(url, {
    method: "PATCH",
    headers,
}).then(response => response.json());

Request      

PATCH api/v1/repairshops/tmRequests/{tmrequest_id}/toWaiting

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

tmrequest_id   integer     

The ID of the tmrequest. Example: 16

PATCH api/v1/repairshops/tmRequests/{tmrequest_id}/toDeparture

Example request:
curl --request PATCH \
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16/toDeparture" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16/toDeparture"
);

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

fetch(url, {
    method: "PATCH",
    headers,
}).then(response => response.json());

Request      

PATCH api/v1/repairshops/tmRequests/{tmrequest_id}/toDeparture

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

tmrequest_id   integer     

The ID of the tmrequest. Example: 16

PATCH api/v1/repairshops/tmRequests/{tmrequest_id}/rollbackToAccepted

Example request:
curl --request PATCH \
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16/rollbackToAccepted" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmRequests/16/rollbackToAccepted"
);

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

fetch(url, {
    method: "PATCH",
    headers,
}).then(response => response.json());

Request      

PATCH api/v1/repairshops/tmRequests/{tmrequest_id}/rollbackToAccepted

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

tmrequest_id   integer     

The ID of the tmrequest. Example: 16

DELETE api/v1/repairshops/tmRequests/info/{tmrequestInfo}/deleteInfo

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/repairshops/tmRequests/info/architecto/deleteInfo" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/repairshops/tmRequests/info/architecto/deleteInfo"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/repairshops/tmRequests/info/{tmrequestInfo}/deleteInfo

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

tmrequestInfo   string     

Example: architecto

GET api/v1/warehouse/units

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/units" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/units"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/units

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

POST api/v1/warehouse/units

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/warehouse/units" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"b\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/units"
);

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

let body = {
    "name": "b"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/warehouse/units

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

name   string     

فیلد value نباید کمتر از 3 کاراکتر باشد. فیلد value نباید بیشتر از 50 کاراکتر باشد. Example: b

GET api/v1/warehouse/units/{id}

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/units/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/units/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/units/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the unit. Example: 16

PUT api/v1/warehouse/units/{id}

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/warehouse/units/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"b\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/units/16"
);

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

let body = {
    "name": "b"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/warehouse/units/{id}

PATCH api/v1/warehouse/units/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the unit. Example: 16

Body Parameters

name   string  optional    

فیلد value نباید کمتر از 3 کاراکتر باشد. فیلد value نباید بیشتر از 50 کاراکتر باشد. Example: b

DELETE api/v1/warehouse/units/{id}

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/warehouse/units/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/units/16"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/warehouse/units/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the unit. Example: 16

GET api/v1/warehouse/storehouses

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/storehouses" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/storehouses"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/storehouses

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

POST api/v1/warehouse/storehouses

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/warehouse/storehouses" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"code\": \"architecto\",
    \"name\": \"architecto\",
    \"address\": \"architecto\",
    \"phone\": \"architecto\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/storehouses"
);

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

let body = {
    "code": "architecto",
    "name": "architecto",
    "address": "architecto",
    "phone": "architecto"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/warehouse/storehouses

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

code   string     

Example: architecto

name   string     

Example: architecto

address   string     

Example: architecto

phone   string     

Example: architecto

GET api/v1/warehouse/storehouses/{id}

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/storehouses/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/storehouses/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/storehouses/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the storehouse. Example: 16

PUT api/v1/warehouse/storehouses/{id}

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/warehouse/storehouses/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"code\": \"architecto\",
    \"name\": \"architecto\",
    \"address\": \"architecto\",
    \"phone\": \"architecto\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/storehouses/16"
);

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

let body = {
    "code": "architecto",
    "name": "architecto",
    "address": "architecto",
    "phone": "architecto"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/warehouse/storehouses/{id}

PATCH api/v1/warehouse/storehouses/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the storehouse. Example: 16

Body Parameters

code   string  optional    

Example: architecto

name   string  optional    

Example: architecto

address   string  optional    

Example: architecto

phone   string  optional    

Example: architecto

DELETE api/v1/warehouse/storehouses/{id}

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/warehouse/storehouses/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/storehouses/16"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/warehouse/storehouses/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the storehouse. Example: 16

GET api/v1/warehouse/products

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/products" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/products"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/products

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

POST api/v1/warehouse/products

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/warehouse/products" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"storehouse_id\": \"architecto\",
    \"unit_id\": \"architecto\",
    \"code\": \"n\",
    \"name\": \"g\",
    \"technical_description\": \"z\",
    \"length\": 4326.4168799999997645500116050243377685546875,
    \"width\": 4326.4168799999997645500116050243377685546875,
    \"height\": 4326.4168799999997645500116050243377685546875,
    \"weight\": 4326.4168799999997645500116050243377685546875,
    \"color\": \"architecto\",
    \"count\": 4326.4168799999997645500116050243377685546875,
    \"single_amount\": 16,
    \"purchase_date\": \"2026-02-21 07:15:20\",
    \"order_threshold\": 4326.4168799999997645500116050243377685546875,
    \"en_description\": \"architecto\",
    \"fa_description\": \"architecto\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/products"
);

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

let body = {
    "storehouse_id": "architecto",
    "unit_id": "architecto",
    "code": "n",
    "name": "g",
    "technical_description": "z",
    "length": 4326.4168799999997645500116050243377685546875,
    "width": 4326.4168799999997645500116050243377685546875,
    "height": 4326.4168799999997645500116050243377685546875,
    "weight": 4326.4168799999997645500116050243377685546875,
    "color": "architecto",
    "count": 4326.4168799999997645500116050243377685546875,
    "single_amount": 16,
    "purchase_date": "2026-02-21 07:15:20",
    "order_threshold": 4326.4168799999997645500116050243377685546875,
    "en_description": "architecto",
    "fa_description": "architecto"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/warehouse/products

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

storehouse_id   string     

The id of an existing record in the storehouses table. Example: architecto

unit_id   string     

The id of an existing record in the units table. Example: architecto

code   string     

فیلد value نباید کمتر از 3 کاراکتر باشد. فیلد value نباید بیشتر از 50 کاراکتر باشد. Example: n

name   string     

فیلد value نباید کمتر از 3 کاراکتر باشد. فیلد value نباید بیشتر از 50 کاراکتر باشد. Example: g

technical_description   string  optional    

فیلد value نباید کمتر از 3 کاراکتر باشد. فیلد value نباید بیشتر از 100 کاراکتر باشد. Example: z

length   number  optional    

Example: 4326.41688

width   number  optional    

Example: 4326.41688

height   number  optional    

Example: 4326.41688

weight   number  optional    

Example: 4326.41688

color   string  optional    

Example: architecto

count   number     

Example: 4326.41688

single_amount   integer     

Example: 16

purchase_date   string     

Must be a valid date in the format Y-m-d H:i:s. Example: 2026-02-21 07:15:20

order_threshold   number     

Example: 4326.41688

en_description   string  optional    

Example: architecto

fa_description   string  optional    

Example: architecto

GET api/v1/warehouse/products/{id}

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/products/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/products/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/products/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the product. Example: 16

PUT api/v1/warehouse/products/{id}

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/warehouse/products/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"code\": \"architecto\",
    \"name\": \"architecto\",
    \"technical_description\": \"architecto\",
    \"color\": \"architecto\",
    \"single_amount\": 11,
    \"purchase_date\": \"2026-02-21 07:15:20\",
    \"en_description\": \"architecto\",
    \"fa_description\": \"architecto\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/products/16"
);

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

let body = {
    "code": "architecto",
    "name": "architecto",
    "technical_description": "architecto",
    "color": "architecto",
    "single_amount": 11,
    "purchase_date": "2026-02-21 07:15:20",
    "en_description": "architecto",
    "fa_description": "architecto"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/warehouse/products/{id}

PATCH api/v1/warehouse/products/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the product. Example: 16

Body Parameters

storehouse_id   string  optional    
unit_id   string  optional    
code   string  optional    

Example: architecto

name   string  optional    

Example: architecto

technical_description   string  optional    

Example: architecto

length   string  optional    
width   string  optional    
height   string  optional    
weight   string  optional    
color   string  optional    

Example: architecto

count   string  optional    
single_amount   integer  optional    

Example: 11

purchase_date   string  optional    

Must be a valid date in the format Y-m-d H:i:s. Example: 2026-02-21 07:15:20

order_threshold   string  optional    
en_description   string  optional    

Example: architecto

fa_description   string  optional    

Example: architecto

DELETE api/v1/warehouse/products/{id}

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/warehouse/products/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/products/16"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/warehouse/products/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the product. Example: 16

PUT api/v1/warehouse/requests/importOrExportAll

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/warehouse/requests/importOrExportAll" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"request_ids\": [
        16
    ]
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/requests/importOrExportAll"
);

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

let body = {
    "request_ids": [
        16
    ]
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/warehouse/requests/importOrExportAll

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

request_ids   integer[]  optional    

PUT api/v1/warehouse/requests/importOrExportOne

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/warehouse/requests/importOrExportOne" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"request_id\": 16,
    \"number_complited\": 16
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/requests/importOrExportOne"
);

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

let body = {
    "request_id": 16,
    "number_complited": 16
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/warehouse/requests/importOrExportOne

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

request_id   integer     

Example: 16

number_complited   integer     

Example: 16

GET api/v1/warehouse/requests

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/requests" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/requests"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/requests

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

POST api/v1/warehouse/requests

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/warehouse/requests" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"request_number\": 16,
    \"applicant_id\": \"architecto\",
    \"approver_id\": \"architecto\",
    \"performer_id\": \"architecto\",
    \"receiver_id\": \"architecto\",
    \"product_id\": \"architecto\",
    \"count\": \"architecto\",
    \"type\": \"request\",
    \"number_completed\": \"architecto\",
    \"work_order_number\": \"architecto\",
    \"comment\": \"architecto\",
    \"status\": \"exported\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/requests"
);

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

let body = {
    "request_number": 16,
    "applicant_id": "architecto",
    "approver_id": "architecto",
    "performer_id": "architecto",
    "receiver_id": "architecto",
    "product_id": "architecto",
    "count": "architecto",
    "type": "request",
    "number_completed": "architecto",
    "work_order_number": "architecto",
    "comment": "architecto",
    "status": "exported"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/warehouse/requests

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

request_number   integer     

Example: 16

applicant_id   string     

Example: architecto

approver_id   string     

Example: architecto

performer_id   string     

Example: architecto

receiver_id   string     

Example: architecto

product_id   string     

The id of an existing record in the products table. Example: architecto

count   string     

Example: architecto

type   string     

Example: request

Must be one of:
  • request
  • buy
number_completed   string     

Example: architecto

work_order_number   string     

Example: architecto

comment   string     

Example: architecto

status   string     

Example: exported

Must be one of:
  • pending
  • approved
  • rejected
  • imported
  • exported

GET api/v1/warehouse/requests/{id}

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/requests/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/requests/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/requests/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the request. Example: 16

PUT api/v1/warehouse/requests/{id}

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/warehouse/requests/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"request_number\": 16,
    \"type\": \"buy\",
    \"comment\": \"architecto\",
    \"status\": \"exported\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/requests/16"
);

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

let body = {
    "request_number": 16,
    "type": "buy",
    "comment": "architecto",
    "status": "exported"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/warehouse/requests/{id}

PATCH api/v1/warehouse/requests/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the request. Example: 16

Body Parameters

request_number   integer  optional    

Example: 16

applicant_id   string  optional    
approver_id   string  optional    
performer_id   string  optional    
receiver_id   string  optional    
product_id   string  optional    
count   string  optional    
type   string  optional    

Example: buy

Must be one of:
  • request
  • buy
number_completed   string  optional    
work_order_number   string  optional    
comment   string  optional    

Example: architecto

status   string  optional    

Example: exported

Must be one of:
  • pending
  • approved
  • rejected
  • imported
  • exported

GET api/v1/warehouse/imports_and_exports

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/imports_and_exports" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/imports_and_exports"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/imports_and_exports

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

GET api/v1/warehouse/transfer_between_storehouses

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/transfer_between_storehouses" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/transfer_between_storehouses"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/transfer_between_storehouses

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

POST api/v1/warehouse/transfer_between_storehouses

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/warehouse/transfer_between_storehouses" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"request_number\": 16,
    \"applicant_id\": \"architecto\",
    \"approver_id\": \"architecto\",
    \"performer_id\": \"architecto\",
    \"receiver_id\": \"architecto\",
    \"product_id\": \"architecto\",
    \"count\": \"architecto\",
    \"type\": \"buy\",
    \"number_completed\": \"architecto\",
    \"work_order_number\": \"architecto\",
    \"comment\": \"architecto\",
    \"status\": \"exported\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/transfer_between_storehouses"
);

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

let body = {
    "request_number": 16,
    "applicant_id": "architecto",
    "approver_id": "architecto",
    "performer_id": "architecto",
    "receiver_id": "architecto",
    "product_id": "architecto",
    "count": "architecto",
    "type": "buy",
    "number_completed": "architecto",
    "work_order_number": "architecto",
    "comment": "architecto",
    "status": "exported"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/warehouse/transfer_between_storehouses

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

request_number   integer     

Example: 16

applicant_id   string     

Example: architecto

approver_id   string     

Example: architecto

performer_id   string     

Example: architecto

receiver_id   string     

Example: architecto

product_id   string     

The id of an existing record in the products table. Example: architecto

count   string     

Example: architecto

type   string     

Example: buy

Must be one of:
  • request
  • buy
number_completed   string     

Example: architecto

work_order_number   string     

Example: architecto

comment   string     

Example: architecto

status   string     

Example: exported

Must be one of:
  • pending
  • approved
  • rejected
  • imported
  • exported

GET api/v1/warehouse/transfer_between_storehouses/{id}

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/transfer_between_storehouses/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/transfer_between_storehouses/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (200):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": [
        "messages.success"
    ],
    "data": {
        "request": []
    }
}
 

Request      

GET api/v1/warehouse/transfer_between_storehouses/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the transfer between storehouse. Example: 16

PUT api/v1/warehouse/transfer_between_storehouses/{id}

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/warehouse/transfer_between_storehouses/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"request_number\": 16,
    \"type\": \"buy\",
    \"comment\": \"architecto\",
    \"status\": \"pending\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/transfer_between_storehouses/16"
);

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

let body = {
    "request_number": 16,
    "type": "buy",
    "comment": "architecto",
    "status": "pending"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/warehouse/transfer_between_storehouses/{id}

PATCH api/v1/warehouse/transfer_between_storehouses/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the transfer between storehouse. Example: 16

Body Parameters

request_number   integer  optional    

Example: 16

applicant_id   string  optional    
approver_id   string  optional    
performer_id   string  optional    
receiver_id   string  optional    
product_id   string  optional    
count   string  optional    
type   string  optional    

Example: buy

Must be one of:
  • request
  • buy
number_completed   string  optional    
work_order_number   string  optional    
comment   string  optional    

Example: architecto

status   string  optional    

Example: pending

Must be one of:
  • pending
  • approved
  • rejected
  • imported
  • exported

GET api/v1/warehouse/storehouse_users

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/storehouse_users" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/storehouse_users"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/storehouse_users

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

POST api/v1/warehouse/storehouse_users

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/warehouse/storehouse_users" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"user_id\": 16,
    \"storehouse_id\": 16
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/storehouse_users"
);

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

let body = {
    "user_id": 16,
    "storehouse_id": 16
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/warehouse/storehouse_users

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

user_id   integer     

Example: 16

storehouse_id   integer     

The id of an existing record in the storehouses table. Example: 16

DELETE api/v1/warehouse/storehouse_users/{id}

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/warehouse/storehouse_users/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/storehouse_users/16"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/warehouse/storehouse_users/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the storehouse user. Example: 16

GET api/v1/warehouse/customers

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/customers" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/customers"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/customers

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

POST api/v1/warehouse/customers

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/warehouse/customers" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"b\",
    \"family\": \"n\",
    \"type\": \"person\",
    \"national_code\": \"gzmiyvdljnikhway\",
    \"phone\": \"architecto\",
    \"zip_code\": \"architecto\",
    \"address\": \"architecto\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/customers"
);

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

let body = {
    "name": "b",
    "family": "n",
    "type": "person",
    "national_code": "gzmiyvdljnikhway",
    "phone": "architecto",
    "zip_code": "architecto",
    "address": "architecto"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/warehouse/customers

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

name   string     

فیلد value نباید کمتر از 2 کاراکتر باشد. فیلد value نباید بیشتر از 50 کاراکتر باشد. Example: b

family   string  optional    

فیلد value نباید کمتر از 2 کاراکتر باشد. فیلد value نباید بیشتر از 30 کاراکتر باشد. Example: n

type   string  optional    

Example: person

Must be one of:
  • person
  • company
national_code   string  optional    

فیلد value نباید کمتر از 10 کاراکتر باشد. فیلد value نباید بیشتر از 20 کاراکتر باشد. Example: gzmiyvdljnikhway

phone   string  optional    

Example: architecto

zip_code   string  optional    

Example: architecto

address   string  optional    

Example: architecto

GET api/v1/warehouse/customers/{id}

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/customers/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/customers/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/customers/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the customer. Example: 16

PUT api/v1/warehouse/customers/{id}

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/warehouse/customers/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"b\",
    \"family\": \"n\",
    \"type\": \"person\",
    \"national_code\": \"gzmiyvdljnikhway\",
    \"phone\": \"architecto\",
    \"zip_code\": \"architecto\",
    \"address\": \"architecto\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/customers/16"
);

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

let body = {
    "name": "b",
    "family": "n",
    "type": "person",
    "national_code": "gzmiyvdljnikhway",
    "phone": "architecto",
    "zip_code": "architecto",
    "address": "architecto"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/warehouse/customers/{id}

PATCH api/v1/warehouse/customers/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the customer. Example: 16

Body Parameters

name   string  optional    

فیلد value نباید کمتر از 2 کاراکتر باشد. فیلد value نباید بیشتر از 50 کاراکتر باشد. Example: b

family   string  optional    

فیلد value نباید کمتر از 2 کاراکتر باشد. فیلد value نباید بیشتر از 30 کاراکتر باشد. Example: n

type   string  optional    

Example: person

Must be one of:
  • person
  • company
national_code   string  optional    

فیلد value نباید کمتر از 10 کاراکتر باشد. فیلد value نباید بیشتر از 20 کاراکتر باشد. Example: gzmiyvdljnikhway

phone   string  optional    

Example: architecto

zip_code   string  optional    

Example: architecto

address   string  optional    

Example: architecto

DELETE api/v1/warehouse/customers/{id}

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/warehouse/customers/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/customers/16"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/warehouse/customers/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the customer. Example: 16

GET api/v1/warehouse/factors

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/factors" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/factors"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/factors

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

POST api/v1/warehouse/factors

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/warehouse/factors" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"customer_id\": \"architecto\",
    \"factor_number\": \"n\",
    \"items\": [
        {
            \"product_id\": \"architecto\",
            \"single_amount\": 39,
            \"count\": 67,
            \"discount\": 12
        }
    ]
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/factors"
);

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

let body = {
    "customer_id": "architecto",
    "factor_number": "n",
    "items": [
        {
            "product_id": "architecto",
            "single_amount": 39,
            "count": 67,
            "discount": 12
        }
    ]
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/warehouse/factors

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

customer_id   string     

The id of an existing record in the customers table. Example: architecto

factor_number   string  optional    

فیلد value نباید بیشتر از 50 کاراکتر باشد. Example: n

items   object[]  optional    

فیلد value نباید کمتر از 1 آیتم داشته باشد.

product_id   string     

The id of an existing record in the products table. Example: architecto

storehouse_id   string  optional    

The id of an existing record in the storehouses table.

single_amount   number     

فیلد value نباید کوچکتر از 0 باشد. Example: 39

count   integer     

فیلد value نباید کوچکتر از 1 باشد. Example: 67

discount   number  optional    

فیلد value نباید کوچکتر از 0 باشد. Example: 12

GET api/v1/warehouse/factors/{id}

Example request:
curl --request GET \
    --get "https://viratest2.ir/api/v1/warehouse/factors/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/factors/16"
);

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

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (500):

Show headers
cache-control: no-cache, private
content-type: application/json
access-control-allow-origin: *
 

{
    "message": "Server Error"
}
 

Request      

GET api/v1/warehouse/factors/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the factor. Example: 16

PUT api/v1/warehouse/factors/{id}

Example request:
curl --request PUT \
    "https://viratest2.ir/api/v1/warehouse/factors/16" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"factor_number\": \"b\",
    \"items\": [
        {
            \"id\": 16,
            \"single_amount\": 39,
            \"count\": 67,
            \"discount\": 12,
            \"_delete\": false
        }
    ]
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/factors/16"
);

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

let body = {
    "factor_number": "b",
    "items": [
        {
            "id": 16,
            "single_amount": 39,
            "count": 67,
            "discount": 12,
            "_delete": false
        }
    ]
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/warehouse/factors/{id}

PATCH api/v1/warehouse/factors/{id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   integer     

The ID of the factor. Example: 16

Body Parameters

customer_id   string  optional    

The id of an existing record in the customers table.

factor_number   string  optional    

فیلد value نباید بیشتر از 50 کاراکتر باشد. Example: b

items   object[]  optional    
id   integer  optional    

The id of an existing record in the factor_items table. Example: 16

product_id   string  optional    

This field is required when items.*.count is present. The id of an existing record in the products table.

storehouse_id   string  optional    

The id of an existing record in the storehouses table.

single_amount   number  optional    

This field is required when items.*.count is present. فیلد value نباید کوچکتر از 0 باشد. Example: 39

count   integer  optional    

This field is required when items.*.single_amount is present. فیلد value نباید کوچکتر از 1 باشد. Example: 67

discount   number  optional    

فیلد value نباید کوچکتر از 0 باشد. Example: 12

_delete   boolean  optional    

Example: false

DELETE api/v1/warehouse/factors/{factor_id}/items/{itemId}

Example request:
curl --request DELETE \
    "https://viratest2.ir/api/v1/warehouse/factors/16/items/architecto" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/factors/16/items/architecto"
);

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

fetch(url, {
    method: "DELETE",
    headers,
}).then(response => response.json());

Request      

DELETE api/v1/warehouse/factors/{factor_id}/items/{itemId}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

factor_id   integer     

The ID of the factor. Example: 16

itemId   string     

Example: architecto

POST api/v1/warehouse/factors/{factor_id}/items/{itemId}/return

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/warehouse/factors/16/items/architecto/return" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/factors/16/items/architecto/return"
);

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

fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/warehouse/factors/{factor_id}/items/{itemId}/return

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

factor_id   integer     

The ID of the factor. Example: 16

itemId   string     

Example: architecto

POST api/v1/warehouse/factors/{factor_id}/confirm

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/warehouse/factors/16/confirm" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/factors/16/confirm"
);

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

fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/warehouse/factors/{factor_id}/confirm

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

factor_id   integer     

The ID of the factor. Example: 16

POST api/v1/warehouse/factors/{factor_id}/cancel

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/warehouse/factors/16/cancel" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/factors/16/cancel"
);

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

fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/warehouse/factors/{factor_id}/cancel

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

factor_id   integer     

The ID of the factor. Example: 16

POST api/v1/warehouse/factors/{factor_id}/payments

Example request:
curl --request POST \
    "https://viratest2.ir/api/v1/warehouse/factors/16/payments" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"amount_paid_by_card\": 27,
    \"amount_paid_by_cash\": 39,
    \"amount_paid_by_check\": 84,
    \"description\": \"Quos velit et fugiat sunt nihil accusantium harum.\"
}"
const url = new URL(
    "https://viratest2.ir/api/v1/warehouse/factors/16/payments"
);

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

let body = {
    "amount_paid_by_card": 27,
    "amount_paid_by_cash": 39,
    "amount_paid_by_check": 84,
    "description": "Quos velit et fugiat sunt nihil accusantium harum."
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/warehouse/factors/{factor_id}/payments

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

factor_id   integer     

The ID of the factor. Example: 16

Body Parameters

amount_paid_by_card   number  optional    

فیلد value نباید کوچکتر از 0 باشد. Example: 27

amount_paid_by_cash   number  optional    

فیلد value نباید کوچکتر از 0 باشد. Example: 39

amount_paid_by_check   number  optional    

فیلد value نباید کوچکتر از 0 باشد. Example: 84

description   string  optional    

فیلد value نباید بیشتر از 500 کاراکتر باشد. Example: Quos velit et fugiat sunt nihil accusantium harum.