Dealers

Operations related to dealers


Parameters

Name In Type Required Description
id path string true Dealer id
Authorization header string true Bearer token

Request example

1
2
3
4
5

curl -X GET https://dealers.masstack.com/v2/dealers/{id}/billing \
  -H "Accept: application/json" \
  -H "Authorization: string"

Responses

Code Meaning Description Schema
200 OK Successfully return the billing information for the dealer BillingOfDealerResponse
400 Bad Request Bad Request ApiErrorResponse
401 Unauthorized Unauthorized ApiErrorResponse
409 Conflict Conflict ApiErrorResponse
500 Internal Server Error Internal Error ApiErrorResponse
503 Service Unavailable Service Unavailable ApiErrorResponse
504 Gateway Time-out Gateway Timeout ApiErrorResponse

Parameters

Name In Type Required Description
id path string true Dealer id
Authorization header string true Bearer token
body body DealerBillingRequest true Body with the dealer billing information

Request body - instance of DealerBillingRequest

1
2
3
{
  "billing_dealer_id": 123456
}
Name Type Required Description
billing_dealer_id integer(int32) true Id of the dealer that bill

Request example

1
2
3
4
5
6
7
8
9

curl -X POST https://dealers.masstack.com/v2/dealers/{id}/billing \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -H "Authorization: string" \
 --data-raw "{
  'billing_dealer_id': 123456
}" 

Responses

Code Meaning Description Schema
201 Created Successfully create the billing information for the dealer None
400 Bad Request Bad Request ApiErrorResponse
401 Unauthorized Unauthorized ApiErrorResponse
404 Not Found BadRequest ApiErrorResponse
409 Conflict Conflict ApiErrorResponse
500 Internal Server Error Internal Error ApiErrorResponse
503 Service Unavailable Service Unavailable ApiErrorResponse
504 Gateway Time-out Gateway Timeout ApiErrorResponse

Parameters

Name In Type Required Description
id path string true Dealer id
Authorization header string true Bearer token

Request example

1
2
3
4
5

curl -X DELETE https://dealers.masstack.com/v2/dealers/{id}/billing \
  -H "Accept: application/json" \
  -H "Authorization: string"

Responses

Code Meaning Description Schema
204 No Content Successfully delete the billing information for the dealer None
400 Bad Request Bad Request ApiErrorResponse
401 Unauthorized Unauthorized ApiErrorResponse
409 Conflict Conflict ApiErrorResponse
500 Internal Server Error Internal Error ApiErrorResponse
503 Service Unavailable Service Unavailable ApiErrorResponse
504 Gateway Time-out Gateway Timeout ApiErrorResponse

Parameters

Name In Type Required Description
id_actor path string true Actor id
id_dealer path string true Dealer id
Authorization header string true Bearer token

Request example

1
2
3
4
5

curl -X POST https://dealers.masstack.com/v2/dealers/{id_dealer}/actors/{id_actor} \
  -H "Accept: application/json" \
  -H "Authorization: string"

Responses

Code Meaning Description Schema
201 Created Successfully created the dealer-actor relationship None
400 Bad Request Bad Request ApiErrorResponse
401 Unauthorized Unauthorized ApiErrorResponse
404 Not Found BadRequest ApiErrorResponse
409 Conflict Conflict ApiErrorResponse
500 Internal Server Error Internal Error ApiErrorResponse
503 Service Unavailable Service Unavailable ApiErrorResponse
504 Gateway Time-out Gateway Timeout ApiErrorResponse

Parameters

Name In Type Required Description
id_dealer path string true Dealer id
id_actor path string true Actor id
Authorization header string true Bearer token

Request example

1
2
3
4
5

curl -X DELETE https://dealers.masstack.com/v2/dealers/{id_dealer}/actors/{id_actor} \
  -H "Accept: application/json" \
  -H "Authorization: string"

Responses

Code Meaning Description Schema
204 No Content Successfully delete the relationship with an actor for the dealer None
400 Bad Request Bad Request ApiErrorResponse
401 Unauthorized Unauthorized ApiErrorResponse
409 Conflict Conflict ApiErrorResponse
500 Internal Server Error Internal Error ApiErrorResponse
503 Service Unavailable Service Unavailable ApiErrorResponse
504 Gateway Time-out Gateway Timeout ApiErrorResponse

Parameters

Name In Type Required Description
id path string true Dealer id
Authorization header string true Bearer token

Request example

1
2
3
4
5

curl -X GET https://dealers.masstack.com/v2/dealers/{id}/ticket-config \
  -H "Accept: application/json" \
  -H "Authorization: string"

Responses

Code Meaning Description Schema
200 OK Return successfully the ticket config information TicketConfigResponse
400 Bad Request Bad Request ApiErrorResponse
401 Unauthorized Unauthorized ApiErrorResponse
409 Conflict Conflict ApiErrorResponse
500 Internal Server Error Internal Error ApiErrorResponse
503 Service Unavailable Service Unavailable ApiErrorResponse
504 Gateway Time-out Gateway Timeout ApiErrorResponse

Parameters

Name In Type Required Description
id path string true Dealer id
Authorization header string true Bearer token
body body TicketConfigUpdateRequest true Body with the dealer ticket config information

Request body - instance of TicketConfigUpdateRequest

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
{
  "commercialName": "Test Commercial Name",
  "address": "Test Address",
  "city": "Test City",
  "province": "Test Province",
  "postalCode": "12345",
  "country": "Test Country",
  "documentType": "NIF",
  "documentNumber": "12345678A",
  "printType": "A4"
}
Name Type Required Description
commercialName string true Commercial name of the ticket config
address string true Address of the ticket config
city string true City of the ticket config
province string true Province of the ticket config
postalCode string true Postal code of the ticket config
country string true Country of the ticket config
documentType string true Document type of the ticket config
documentNumber string true Document number of the ticket config
printType string true Print type of the ticket config

Request example

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17

curl -X PUT https://dealers.masstack.com/v2/dealers/{id}/ticket-config \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -H "Authorization: string" \
 --data-raw "{
  'commercialName': 'Test Commercial Name',
  'address': 'Test Address',
  'city': 'Test City',
  'province': 'Test Province',
  'postalCode': '12345',
  'country': 'Test Country',
  'documentType': 'NIF',
  'documentNumber': '12345678A',
  'printType': 'A4'
}" 

Responses

Code Meaning Description Schema
204 No Content Successfully update the dealer’s ticket config None
400 Bad Request Bad Request ApiErrorResponse
401 Unauthorized Unauthorized ApiErrorResponse
409 Conflict Conflict ApiErrorResponse
500 Internal Server Error Internal Error ApiErrorResponse
503 Service Unavailable Service Unavailable ApiErrorResponse
504 Gateway Time-out Gateway Timeout ApiErrorResponse

Parameters

Name In Type Required Description
id path string true Dealer id
Authorization header string true Bearer token
body body TicketConfigInsertRequest true Body with the dealer ticket config information

Request body - instance of TicketConfigInsertRequest

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
{
  "commercialName": "Test Commercial Name",
  "address": "Test Address",
  "city": "Test City",
  "province": "Test Province",
  "postalCode": "12345",
  "country": "Test Country",
  "documentType": "NIF",
  "documentNumber": "12345678A",
  "printType": "A4"
}
Name Type Required Description
commercialName string false Commercial name of the ticket config
address string false Address of the ticket config
city string false City of the ticket config
province string false Province of the ticket config
postalCode string false Postal code of the ticket config
country string false Country of the ticket config
documentType string false Document type of the ticket config
documentNumber string false Document number of the ticket config
printType string false Print type of the ticket config

Request example

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17

curl -X POST https://dealers.masstack.com/v2/dealers/{id}/ticket-config \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -H "Authorization: string" \
 --data-raw "{
  'commercialName': 'Test Commercial Name',
  'address': 'Test Address',
  'city': 'Test City',
  'province': 'Test Province',
  'postalCode': '12345',
  'country': 'Test Country',
  'documentType': 'NIF',
  'documentNumber': '12345678A',
  'printType': 'A4'
}" 

Responses

Code Meaning Description Schema
201 Created Successfully create the ticket config for the dealer None
400 Bad Request Bad Request ApiErrorResponse
401 Unauthorized Unauthorized ApiErrorResponse
409 Conflict Conflict ApiErrorResponse
500 Internal Server Error Internal Error ApiErrorResponse
503 Service Unavailable Service Unavailable ApiErrorResponse
504 Gateway Time-out Gateway Timeout ApiErrorResponse

Parameters

Name In Type Required Description
id path string true Dealer id
Authorization header string true Bearer token

Request example

1
2
3
4
5

curl -X DELETE https://dealers.masstack.com/v2/dealers/{id}/ticket-config \
  -H "Accept: application/json" \
  -H "Authorization: string"

Responses

Code Meaning Description Schema
204 No Content Successfully delete the dealer’s ticket config None
400 Bad Request Bad Request ApiErrorResponse
401 Unauthorized Unauthorized ApiErrorResponse
409 Conflict Conflict ApiErrorResponse
500 Internal Server Error Internal Error ApiErrorResponse
503 Service Unavailable Service Unavailable ApiErrorResponse
504 Gateway Time-out Gateway Timeout ApiErrorResponse

Parameters

Name In Type Required Description
id path string true Dealer id
Authorization header string true Bearer token
limit query integer(int64) false Limit of results in the response
offset query integer(int64) false Offset applied to results for pagination
sort query string false The fields by which the results will be sorted. It can be a list of fields separated by commas. A suffix must be added:
* “:asc” to indicate an ascending order.
* “:desc” to indicate a descending order.

Request example

1
2
3
4
5

curl -X GET https://dealers.masstack.com/v2/dealers/billing/{id}?limit='20'&offset='0'&sort='name:asc,id:desc' \
  -H "Accept: application/json" \
  -H "Authorization: string"

Responses

Code Meaning Description Schema
200 OK Successfully return the list of the dealers that have a relation with the queried billing dealer DealersResponse
400 Bad Request Bad Request ApiErrorResponse
401 Unauthorized Unauthorized ApiErrorResponse
409 Conflict Conflict ApiErrorResponse
500 Internal Server Error Internal Error ApiErrorResponse
503 Service Unavailable Service Unavailable ApiErrorResponse
504 Gateway Time-out Gateway Timeout ApiErrorResponse

Parameters

Name In Type Required Description
Authorization header string true Bearer token
code query string true Dealer code
limit query integer(int64) false Limit of results in the response
offset query integer(int64) false Offset applied to results for pagination
sort query string false The fields by which the results will be sorted. It can be a list of fields separated by commas. A suffix must be added:
* “:asc” to indicate an ascending order.
* “:desc” to indicate a descending order.

Request example

1
2
3
4
5

curl -X GET https://dealers.masstack.com/v2/dealers?code='string'&limit='20'&offset='0'&sort='name:asc,id:desc'?code=string \
  -H "Accept: application/json" \
  -H "Authorization: string"

Responses

Code Meaning Description Schema
200 OK Successfully return the list of the dealers that have this dealerCode DealersResponse
400 Bad Request Bad Request ApiErrorResponse
401 Unauthorized Unauthorized ApiErrorResponse
404 Not Found BadRequest ApiErrorResponse
409 Conflict Conflict ApiErrorResponse
500 Internal Server Error Internal Error ApiErrorResponse
503 Service Unavailable Service Unavailable ApiErrorResponse
504 Gateway Time-out Gateway Timeout ApiErrorResponse

Parameters

Name In Type Required Description
Authorization header string true Bearer token

Request example

1
2
3
4
5

curl -X POST https://dealers.masstack.com/v2/dealers/fix-geocoding \
  -H "Accept: application/json" \
  -H "Authorization: string"

Responses

Code Meaning Description Schema
201 Created Successfully processed the fix geocoding request FixGeocodingResponse
400 Bad Request Bad Request ApiErrorResponse
401 Unauthorized Unauthorized ApiErrorResponse
409 Conflict Conflict ApiErrorResponse
500 Internal Server Error Internal Error ApiErrorResponse
503 Service Unavailable Service Unavailable ApiErrorResponse
504 Gateway Time-out Gateway Timeout ApiErrorResponse

Endpoints

Loads

    Actors

      Dealers