MENU navbar-image

Introduction

API documentation for developers

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

Authenticating requests

To authenticate requests, include an Authorization header with the value "Bearer {YOUR_AUTH_KEY}".

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

Our API is currently not available for external access outside of the Smarter Launch application.

Service Plan

API for Service Plans

List

requires authentication

Shows the list of Service Plans with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/service-plans" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans"
);

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

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

Request      

GET api/v1/service-plans

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 7

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 16

sort_by   string  optional  

The column name. Example : name Example: sit

sort_order   string  optional  

The order in which you want your records. Example : asc Example: asperiores

search   string  optional  

The general search, it will find matching string. Example : home Example: ducimus

string   string  optional  

The filter for service plans with status in statuses_uuid. Example: ["725d1dcd-54ad-3a8b-a28e-830c43d8ed6c", "b033658c-4532-3dd7-9be7-64433580eda6"]

Get

requires authentication

Shows the specified Service Plan.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/service-plans/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2"
);

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

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

Request      

GET api/v1/service-plans/{servicePlan_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

Create

requires authentication

Store a newly created Service Plan.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Premium Service Plan\",
    \"display_name\": \"sit\",
    \"description\": \"Lorem ipsum dolor sit amet consectetur adipisicing elit\",
    \"company_locations_uuid\": [
        \"10933939-447e-3d2c-944f-b3ef57dc6eeb\",
        \"10933939-447e-3d2c-944f-b3ef57dc6eeb\"
    ],
    \"categories_uuid\": [
        \"10933939-447e-3d2c-944f-b3ef57dc6eeb\",
        \"10933939-447e-3d2c-944f-b3ef57dc6eeb\"
    ],
    \"default_contract_term_units\": 28454150.70456
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Premium Service Plan',
            'display_name' => 'sit',
            'description' => 'Lorem ipsum dolor sit amet consectetur adipisicing elit',
            'company_locations_uuid' => [
                '10933939-447e-3d2c-944f-b3ef57dc6eeb',
                '10933939-447e-3d2c-944f-b3ef57dc6eeb',
            ],
            'categories_uuid' => [
                '10933939-447e-3d2c-944f-b3ef57dc6eeb',
                '10933939-447e-3d2c-944f-b3ef57dc6eeb',
            ],
            'default_contract_term_units' => 28454150.70456,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans"
);

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

let body = {
    "name": "Premium Service Plan",
    "display_name": "sit",
    "description": "Lorem ipsum dolor sit amet consectetur adipisicing elit",
    "company_locations_uuid": [
        "10933939-447e-3d2c-944f-b3ef57dc6eeb",
        "10933939-447e-3d2c-944f-b3ef57dc6eeb"
    ],
    "categories_uuid": [
        "10933939-447e-3d2c-944f-b3ef57dc6eeb",
        "10933939-447e-3d2c-944f-b3ef57dc6eeb"
    ],
    "default_contract_term_units": 28454150.70456
};

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

Request      

POST api/v1/service-plans

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

name   string   

The name of Service Plan. Example: Premium Service Plan

display_name   string  optional  

Example: sit

description   string  optional  

The description of Service Plan. Example: Lorem ipsum dolor sit amet consectetur adipisicing elit

company_locations_uuid   string[]  optional  

List of company_location_uuid.

categories_uuid   string[]  optional  

List of category_uuid. Example:

default_contract_term   string  optional  
default_contract_term_units   number  optional  

Example: 28454150.70456

Duplicate

requires authentication

This endpoint lets user to duplicate service plan and set into a draft mode

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/duplicate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/duplicate';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/duplicate"
);

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

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

Request      

POST api/v1/service-plans/{servicePlan_uuid}/duplicate

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

service_plan_uuid   string  optional  

uuid required The uuid of the service plan. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Update

requires authentication

Perform a full field update for the specified Service Plan.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Premium Service Plan\",
    \"display_name\": \"quia\",
    \"description\": \"Lorem ipsum dolor sit amet consectetur adipisicing elit\",
    \"company_locations_uuid\": [
        \"10933939-447e-3d2c-944f-b3ef57dc6eeb\",
        \"10933939-447e-3d2c-944f-b3ef57dc6eeb\"
    ],
    \"categories_uuid\": [
        \"10933939-447e-3d2c-944f-b3ef57dc6eeb\",
        \"10933939-447e-3d2c-944f-b3ef57dc6eeb\"
    ],
    \"default_contract_term_units\": 27606.347593,
    \"save_as\": \"SERVICE_PLAN_ACTIVE\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Premium Service Plan',
            'display_name' => 'quia',
            'description' => 'Lorem ipsum dolor sit amet consectetur adipisicing elit',
            'company_locations_uuid' => [
                '10933939-447e-3d2c-944f-b3ef57dc6eeb',
                '10933939-447e-3d2c-944f-b3ef57dc6eeb',
            ],
            'categories_uuid' => [
                '10933939-447e-3d2c-944f-b3ef57dc6eeb',
                '10933939-447e-3d2c-944f-b3ef57dc6eeb',
            ],
            'default_contract_term_units' => 27606.347593,
            'save_as' => 'SERVICE_PLAN_ACTIVE',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2"
);

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

let body = {
    "name": "Premium Service Plan",
    "display_name": "quia",
    "description": "Lorem ipsum dolor sit amet consectetur adipisicing elit",
    "company_locations_uuid": [
        "10933939-447e-3d2c-944f-b3ef57dc6eeb",
        "10933939-447e-3d2c-944f-b3ef57dc6eeb"
    ],
    "categories_uuid": [
        "10933939-447e-3d2c-944f-b3ef57dc6eeb",
        "10933939-447e-3d2c-944f-b3ef57dc6eeb"
    ],
    "default_contract_term_units": 27606.347593,
    "save_as": "SERVICE_PLAN_ACTIVE"
};

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

Request      

PUT api/v1/service-plans/{servicePlan_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

Body Parameters

name   string   

The name of Service Plan. Example: Premium Service Plan

display_name   string  optional  

Example: quia

description   string  optional  

The description of Service Plan. Example: Lorem ipsum dolor sit amet consectetur adipisicing elit

company_locations_uuid   string[]  optional  

List of company_location_uuid.

categories_uuid   string[]  optional  

List of category_uuid. Example:

default_contract_term   string  optional  
default_contract_term_units   number  optional  

Example: 27606.347593

save_as   string  optional  

Example: SERVICE_PLAN_ACTIVE

Must be one of:
  • SERVICE_PLAN_DRAFT
  • SERVICE_PLAN_ACTIVE
  • SERVICE_PLAN_ARCHIVED

Patch

requires authentication

Perform a patch for the specified Service Plan.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Premium Service Plan\",
    \"display_name\": \"et\",
    \"description\": \"Lorem ipsum dolor sit amet consectetur adipisicing elit\",
    \"company_locations_uuid\": [
        \"10933939-447e-3d2c-944f-b3ef57dc6eeb\",
        \"10933939-447e-3d2c-944f-b3ef57dc6eeb\"
    ],
    \"categories_uuid\": [
        \"10933939-447e-3d2c-944f-b3ef57dc6eeb\",
        \"10933939-447e-3d2c-944f-b3ef57dc6eeb\"
    ],
    \"default_contract_term_units\": 67.6,
    \"save_as\": \"SERVICE_PLAN_ARCHIVED\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Premium Service Plan',
            'display_name' => 'et',
            'description' => 'Lorem ipsum dolor sit amet consectetur adipisicing elit',
            'company_locations_uuid' => [
                '10933939-447e-3d2c-944f-b3ef57dc6eeb',
                '10933939-447e-3d2c-944f-b3ef57dc6eeb',
            ],
            'categories_uuid' => [
                '10933939-447e-3d2c-944f-b3ef57dc6eeb',
                '10933939-447e-3d2c-944f-b3ef57dc6eeb',
            ],
            'default_contract_term_units' => 67.6,
            'save_as' => 'SERVICE_PLAN_ARCHIVED',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2"
);

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

let body = {
    "name": "Premium Service Plan",
    "display_name": "et",
    "description": "Lorem ipsum dolor sit amet consectetur adipisicing elit",
    "company_locations_uuid": [
        "10933939-447e-3d2c-944f-b3ef57dc6eeb",
        "10933939-447e-3d2c-944f-b3ef57dc6eeb"
    ],
    "categories_uuid": [
        "10933939-447e-3d2c-944f-b3ef57dc6eeb",
        "10933939-447e-3d2c-944f-b3ef57dc6eeb"
    ],
    "default_contract_term_units": 67.6,
    "save_as": "SERVICE_PLAN_ARCHIVED"
};

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

Request      

PATCH api/v1/service-plans/{servicePlan_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

Body Parameters

name   string  optional  

requiredThe name of Service Plan. Example: Premium Service Plan

display_name   string  optional  

Example: et

description   string  optional  

The description of Service Plan. Example: Lorem ipsum dolor sit amet consectetur adipisicing elit

company_locations_uuid   string[]  optional  

List of company_location_uuid.

categories_uuid   string[]  optional  

List of category_uuid. Example:

settings   object  optional  
default_contract_term   string  optional  
default_contract_term_units   number  optional  

Example: 67.6

save_as   string  optional  

Example: SERVICE_PLAN_ARCHIVED

Must be one of:
  • SERVICE_PLAN_DRAFT
  • SERVICE_PLAN_ACTIVE
  • SERVICE_PLAN_ARCHIVED

Save as Draft

requires authentication

Save as Draft the specified Service Plan.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/draft" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/draft';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/draft"
);

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

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

Request      

PATCH api/v1/service-plans/{servicePlan_uuid}/draft

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

Publish

requires authentication

Publish the specified Service Plan.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/publish" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/publish';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/publish"
);

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

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

Request      

PATCH api/v1/service-plans/{servicePlan_uuid}/publish

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

Archived

requires authentication

Archived the specified Service Plan.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/archive" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/archive';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/archive"
);

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

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

Request      

PATCH api/v1/service-plans/{servicePlan_uuid}/archive

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

Unarchived

requires authentication

Unarchived the specified Service Plan.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/unarchive" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/unarchive';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/unarchive"
);

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

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

Request      

PATCH api/v1/service-plans/{servicePlan_uuid}/unarchive

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

Delete

requires authentication

Remove the specified Service Plan.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2"
);

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

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

Request      

DELETE api/v1/service-plans/{servicePlan_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

Decline Reason

API for Decline Reason

List

requires authentication

Shows the list of decline reasons with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/decline-reasons

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 4

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 15

sort_by   string  optional  

The column name. Example : name Example: amet

sort_order   string  optional  

The order in which you want your records. Example : asc Example: tempore

search   string  optional  

The general search, it will find matching string. Example : home Example: sed

Show

requires authentication

Show a single decline reason.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons/1"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/decline-reasons/{declineReason_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

declineReason_uuid   integer   

Example: 1

Store

requires authentication

Store a newly created decline reasons.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"placeat\",
    \"description\": \"Lorem, ipsum dolor sit amet consectetur adipisicing elit.\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => 'placeat',
            'description' => 'Lorem, ipsum dolor sit amet consectetur adipisicing elit.',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons"
);

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

let body = {
    "title": "placeat",
    "description": "Lorem, ipsum dolor sit amet consectetur adipisicing elit."
};

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

Request      

POST api/v1/companies/{company_uuid}/decline-reasons

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

title   string   

The title of the decline reasons. Example : So Expensive Example: placeat

description   object  optional  

The description of the decline reasons. Example: Lorem, ipsum dolor sit amet consectetur adipisicing elit.

Update

requires authentication

Update a decline reason.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"rerum\",
    \"description\": \"Lorem, ipsum dolor sit amet consectetur adipisicing elit.\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => 'rerum',
            'description' => 'Lorem, ipsum dolor sit amet consectetur adipisicing elit.',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons/1"
);

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

let body = {
    "title": "rerum",
    "description": "Lorem, ipsum dolor sit amet consectetur adipisicing elit."
};

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

Request      

PUT api/v1/companies/{company_uuid}/decline-reasons/{declineReason_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

declineReason_uuid   integer   

Example: 1

Body Parameters

title   string   

The title of the decline reasons. Example : "So Expensive" Example: rerum

description   object  optional  

The description of the decline reasons. Example: Lorem, ipsum dolor sit amet consectetur adipisicing elit.

Patch

requires authentication

Patch a company decline reason.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"iure\",
    \"description\": \"Lorem, ipsum dolor sit amet consectetur adipisicing elit.\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => 'iure',
            'description' => 'Lorem, ipsum dolor sit amet consectetur adipisicing elit.',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons/1"
);

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

let body = {
    "title": "iure",
    "description": "Lorem, ipsum dolor sit amet consectetur adipisicing elit."
};

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

Request      

PATCH api/v1/companies/{company_uuid}/decline-reasons/{declineReason_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

declineReason_uuid   integer   

Example: 1

Body Parameters

title   string   

The title of the decline reasons. Example : So Expensive Example: iure

description   object  optional  

The description of the decline reasons. Example: Lorem, ipsum dolor sit amet consectetur adipisicing elit.

Delete

requires authentication

Delete a decline reason.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/decline-reasons/1"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/decline-reasons/{declineReason_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

declineReason_uuid   integer   

Example: 1

Automation

API for Automation

List

requires authentication

Shows the list of Automations with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/automations" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/automations';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/automations"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/automations

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 17

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 12

sort_by   string  optional  

The column name. Example : name Example: et

sort_order   string  optional  

The order in which you want your records. Example : asc Example: quia

search   string  optional  

The general search, it will find matching string. Example : home Example: nisi

is_enabled   string  optional  

boolean Filter by enabled status. Example : true Example: reiciendis

Create

requires authentication

Store a newly created Automation.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/automations" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Small Pests\",
    \"description\": \"Lorem ipsum dolor sit amet consectetur adipisicing elit\",
    \"type\": \"Lorem ipsum dolor sit amet consectetur adipisicing elit\",
    \"actions\": [
        \"nostrum\"
    ],
    \"filters\": [
        \"aut\"
    ],
    \"triggers\": [
        \"occaecati\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/automations';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Small Pests',
            'description' => 'Lorem ipsum dolor sit amet consectetur adipisicing elit',
            'type' => 'Lorem ipsum dolor sit amet consectetur adipisicing elit',
            'actions' => [
                'nostrum',
            ],
            'filters' => [
                'aut',
            ],
            'triggers' => [
                'occaecati',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/automations"
);

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

let body = {
    "name": "Small Pests",
    "description": "Lorem ipsum dolor sit amet consectetur adipisicing elit",
    "type": "Lorem ipsum dolor sit amet consectetur adipisicing elit",
    "actions": [
        "nostrum"
    ],
    "filters": [
        "aut"
    ],
    "triggers": [
        "occaecati"
    ]
};

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

Request      

POST api/v1/companies/{company_uuid}/automations

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the automation. Example: Small Pests

description   string  optional  

The description of the automation. Example: Lorem ipsum dolor sit amet consectetur adipisicing elit

type   string   

The type of the automation. Example: Lorem ipsum dolor sit amet consectetur adipisicing elit

actions   string[]  optional  

of object required The actions of automation. Example : [{action: "SEND_EMAIL", value: ["john@smarterlaunch.com", "smith@smarterlaunch.com"], settings: {body: "Please follow-up with this and set an appointment."}}]

filters   string[]  optional  

of object required The filters of automation. Example : [{type: "CUSTOMER",operator: "IS",value: "3245d630-24fd-11ec-accd-e397aec85c7f",}, {type: "USER",operator: "IS_ONE_OF",value: ["3245d630-24fd-11ec-accd-e397aec85c7f", "3245d630-24fd-11ec-accd-e397aec85c7h"]}]

triggers   string[]  optional  

of object required The triggers of automation. Example : [{type: "CUSTOMER",operator: "IS_CHANGED_TO",value: "3245d630-24fd-11ec-accd-e397aec85c7f"}]

Get

requires authentication

Display the specified Automation.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/automations/3" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/automations/3';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/automations/3"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/automations/{automation_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

automation_uuid   integer   

Example: 3

Update

requires authentication

Modify the specified Automation.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/automations/3" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Small Pests\",
    \"description\": \"Lorem ipsum dolor sit amet consectetur adipisicing elit\",
    \"type\": \"Lorem ipsum dolor sit amet consectetur adipisicing elit\",
    \"actions\": [
        \"voluptatem\"
    ],
    \"filters\": [
        \"perspiciatis\"
    ],
    \"triggers\": [
        \"dolore\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/automations/3';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Small Pests',
            'description' => 'Lorem ipsum dolor sit amet consectetur adipisicing elit',
            'type' => 'Lorem ipsum dolor sit amet consectetur adipisicing elit',
            'actions' => [
                'voluptatem',
            ],
            'filters' => [
                'perspiciatis',
            ],
            'triggers' => [
                'dolore',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/automations/3"
);

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

let body = {
    "name": "Small Pests",
    "description": "Lorem ipsum dolor sit amet consectetur adipisicing elit",
    "type": "Lorem ipsum dolor sit amet consectetur adipisicing elit",
    "actions": [
        "voluptatem"
    ],
    "filters": [
        "perspiciatis"
    ],
    "triggers": [
        "dolore"
    ]
};

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

Request      

PUT api/v1/companies/{company_uuid}/automations/{automation_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

automation_uuid   integer   

Example: 3

automationUuid   string   

The uuid of the automation. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

name   string   

The name of the automation. Example: Small Pests

description   string  optional  

The description of the automation. Example: Lorem ipsum dolor sit amet consectetur adipisicing elit

type   string   

The type of the automation. Example: Lorem ipsum dolor sit amet consectetur adipisicing elit

actions   string[]  optional  

of object required The actions of automation. Example : [{action: "SEND_EMAIL",value: ["john@smarterlaunch.com", "smith@smarterlaunch.com"], settings: {body: "Please follow-up with this and set an appointment."}}]

filters   string[]  optional  

of object required The filters of automation. Example : [{type: "CUSTOMER",operator: "IS", value: "3245d630-24fd-11ec-accd-e397aec85c7f",}, {type: "USER",operator: "IS_ONE_OF", value: ["3245d630-24fd-11ec-accd-e397aec85c7f", "3245d630-24fd-11ec-accd-e397aec85c7h"]}]

triggers   string[]  optional  

of object required The triggers of automation. Example : [{type: "CUSTOMER",operator: "IS_CHANGED_TO",value: "3245d630-24fd-11ec-accd-e397aec85c7f"}]

Patch

requires authentication

Perform patches for the specified Automation.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/automations/3" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Small Pests\",
    \"description\": \"Lorem ipsum dolor sit amet consectetur adipisicing elit\",
    \"type\": \"Lorem ipsum dolor sit amet consectetur adipisicing elit\",
    \"actions\": [
        \"explicabo\"
    ],
    \"filters\": [
        \"expedita\"
    ],
    \"triggers\": [
        \"dignissimos\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/automations/3';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Small Pests',
            'description' => 'Lorem ipsum dolor sit amet consectetur adipisicing elit',
            'type' => 'Lorem ipsum dolor sit amet consectetur adipisicing elit',
            'actions' => [
                'explicabo',
            ],
            'filters' => [
                'expedita',
            ],
            'triggers' => [
                'dignissimos',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/automations/3"
);

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

let body = {
    "name": "Small Pests",
    "description": "Lorem ipsum dolor sit amet consectetur adipisicing elit",
    "type": "Lorem ipsum dolor sit amet consectetur adipisicing elit",
    "actions": [
        "explicabo"
    ],
    "filters": [
        "expedita"
    ],
    "triggers": [
        "dignissimos"
    ]
};

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

Request      

PATCH api/v1/companies/{company_uuid}/automations/{automation_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

automation_uuid   integer   

Example: 3

automationUuid   string   

The uuid of the automation. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

name   string  optional  

The name of the automation. Example: Small Pests

description   string  optional  

The description of the automation. Example: Lorem ipsum dolor sit amet consectetur adipisicing elit

type   string  optional  

The type of the automation. Example: Lorem ipsum dolor sit amet consectetur adipisicing elit

actions   string[]  optional  

of object The actions of automation. Example : [{action: "SEND_EMAIL", value: ["john@smarterlaunch.com", "smith@smarterlaunch.com"], settings: {body: "Please follow-up with this and set an appointment."}}]

filters   string[]  optional  

of object The filters of automation. Example : [{type: "CUSTOMER",operator: "IS", value: "3245d630-24fd-11ec-accd-e397aec85c7f",}, {type: "USER",operator: "IS_ONE_OF", value: ["3245d630-24fd-11ec-accd-e397aec85c7f", "3245d630-24fd-11ec-accd-e397aec85c7h"]}]

triggers   string[]  optional  

of object The triggers of automation. Example : [{type: "CUSTOMER",operator: "IS_CHANGED_TO",value: "3245d630-24fd-11ec-accd-e397aec85c7f"}]

Delete

requires authentication

Remove the specified Automation.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/automations/3" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/automations/3';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/automations/3"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/automations/{automation_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

automation_uuid   integer   

Example: 3

Heartbeat

API for Heartbeat

Lock

requires authentication

Lock a specific item of given the type for editing

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/heartbeat" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"type\": \"\\\"Proposal\\\"\",
    \"uuid\": \"\\\"f26834b1-b086-3c99-adc7-b1660383a3fd\\\"\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/heartbeat';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'type' => '"Proposal"',
            'uuid' => '"f26834b1-b086-3c99-adc7-b1660383a3fd"',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/heartbeat"
);

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

let body = {
    "type": "\"Proposal\"",
    "uuid": "\"f26834b1-b086-3c99-adc7-b1660383a3fd\""
};

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

Request      

POST api/v1/heartbeat

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

type   string   

The type of endpoint to be locked. Example: "Proposal"

uuid   string   

The uuid of the specific item. Example: "f26834b1-b086-3c99-adc7-b1660383a3fd"

Unlock

requires authentication

Unlock a specific item of given the type for editing

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/heartbeat" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"type\": \"\\\"Proposal\\\"\",
    \"uuid\": \"\\\"f26834b1-b086-3c99-adc7-b1660383a3fd\\\"\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/heartbeat';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'type' => '"Proposal"',
            'uuid' => '"f26834b1-b086-3c99-adc7-b1660383a3fd"',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/heartbeat"
);

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

let body = {
    "type": "\"Proposal\"",
    "uuid": "\"f26834b1-b086-3c99-adc7-b1660383a3fd\""
};

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

Request      

DELETE api/v1/heartbeat

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

type   string   

The type of endpoint to be unlocked. Example: "Proposal"

uuid   string   

The uuid of the specific item. Example: "f26834b1-b086-3c99-adc7-b1660383a3fd"

Role

API for role details

List / Fetch

requires authentication

Shows the list of role or fetch single record using uuid.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/roles" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\",
    \"name\": \"admin\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/roles';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
            'name' => 'admin',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/roles"
);

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

let body = {
    "uuid": "3245d630-24fd-11ec-accd-e397aec85c7f",
    "name": "admin"
};

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

Request      

GET api/v1/roles

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

uuid   string  optional  

optional The uuid of the role. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

name   string  optional  

optional The role name. Example: admin

List / Fetch

requires authentication

Shows the list of role or fetch single record using uuid.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/roles/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\",
    \"name\": \"admin\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/roles/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
            'name' => 'admin',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/roles/1"
);

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

let body = {
    "uuid": "3245d630-24fd-11ec-accd-e397aec85c7f",
    "name": "admin"
};

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

Request      

GET api/v1/roles/{roleUuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

roleUuid   integer   

Example: 1

Body Parameters

uuid   string  optional  

optional The uuid of the role. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

name   string  optional  

optional The role name. Example: admin

Create / Update role.

requires authentication

This endpoint lets user to create/update role.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/roles" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"admin\",
    \"uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/roles';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'admin',
            'uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/roles"
);

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

let body = {
    "name": "admin",
    "uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4"
};

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

Request      

POST api/v1/roles

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

name   string   

The name of the role. Example: admin

uuid   string  optional  

optional The uuid of the role. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

Create / Update role.

requires authentication

This endpoint lets user to create/update role.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/roles/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"admin\",
    \"uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/roles/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'admin',
            'uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/roles/1"
);

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

let body = {
    "name": "admin",
    "uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4"
};

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

Request      

PUT api/v1/roles/{roleUuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

roleUuid   integer   

Example: 1

Body Parameters

name   string   

The name of the role. Example: admin

uuid   string  optional  

optional The uuid of the role. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

Delete

requires authentication

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/roles/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/roles/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/roles/1"
);

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

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

Request      

DELETE api/v1/roles/{roleUuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

roleUuid   integer   

Example: 1

uuid   string   

The uuid of the role. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Review

API for Review

List

requires authentication

Shows the list of review with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/reviews

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 15

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 14

sort_by   string  optional  

The column name. Example : name Example: dolorum

sort_order   string  optional  

The order in which you want your records. Example : asc Example: et

search   string  optional  

The general search, it will find matching string. Example : home Example: voluptas

is_all_location   string  optional  

boolean Will get all reviews that is not company location specific. Example : true Example: quia

Show

requires authentication

Show a single review.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews/1"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/reviews/{review_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

review_uuid   integer   

Example: 1

Store

requires authentication

Store a newly created review.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "name=et"\
    --form "message=sed"\
    --form "rate=nulla"\
    --form "external_photo_url=http://www.kuhlman.biz/"\
    --form "position=4"\
    --form "company_location_uuid=8b721c17-3368-3688-afe9-30d1e9ce3790"\
    --form "photo=@/tmp/php3B3o9P" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'name',
                'contents' => 'et'
            ],
            [
                'name' => 'message',
                'contents' => 'sed'
            ],
            [
                'name' => 'rate',
                'contents' => 'nulla'
            ],
            [
                'name' => 'external_photo_url',
                'contents' => 'http://www.kuhlman.biz/'
            ],
            [
                'name' => 'position',
                'contents' => '4'
            ],
            [
                'name' => 'company_location_uuid',
                'contents' => '8b721c17-3368-3688-afe9-30d1e9ce3790'
            ],
            [
                'name' => 'photo',
                'contents' => fopen('/tmp/php3B3o9P', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('name', 'et');
body.append('message', 'sed');
body.append('rate', 'nulla');
body.append('external_photo_url', 'http://www.kuhlman.biz/');
body.append('position', '4');
body.append('company_location_uuid', '8b721c17-3368-3688-afe9-30d1e9ce3790');
body.append('photo', document.querySelector('input[name="photo"]').files[0]);

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

Request      

POST api/v1/companies/{company_uuid}/reviews

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the customer/reviewer. Example : "My Review" Example: et

message   string  optional  

The message of the review. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: sed

rate   string   

The rate of the review ranging from 0-5. Example : 5 Example: nulla

photo   file  optional  

The file photo of the review..jpg, .jpeg, .png Example: /tmp/php3B3o9P

external_photo_url   string  optional  

An external url of an image as review/photo. Example: http://www.kuhlman.biz/

position   integer  optional  

The the position of the review. Example : 2 Example: 4

company_location_uuid   uuid  optional  

The company location to be associated to the review. Leaving empty/blank means visible to all company locations. Example: 8b721c17-3368-3688-afe9-30d1e9ce3790

Update

requires authentication

Update a review.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "name=nihil"\
    --form "message=consectetur"\
    --form "rate=ut"\
    --form "external_photo_url=http://www.jast.com/"\
    --form "position=18"\
    --form "company_location_uuid=f7385aa8-02f2-3bd0-8644-56e31b893e48"\
    --form "photo=@/tmp/phpfhG7iR" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews/1';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'name',
                'contents' => 'nihil'
            ],
            [
                'name' => 'message',
                'contents' => 'consectetur'
            ],
            [
                'name' => 'rate',
                'contents' => 'ut'
            ],
            [
                'name' => 'external_photo_url',
                'contents' => 'http://www.jast.com/'
            ],
            [
                'name' => 'position',
                'contents' => '18'
            ],
            [
                'name' => 'company_location_uuid',
                'contents' => 'f7385aa8-02f2-3bd0-8644-56e31b893e48'
            ],
            [
                'name' => 'photo',
                'contents' => fopen('/tmp/phpfhG7iR', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews/1"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('name', 'nihil');
body.append('message', 'consectetur');
body.append('rate', 'ut');
body.append('external_photo_url', 'http://www.jast.com/');
body.append('position', '18');
body.append('company_location_uuid', 'f7385aa8-02f2-3bd0-8644-56e31b893e48');
body.append('photo', document.querySelector('input[name="photo"]').files[0]);

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

Request      

POST api/v1/companies/{company_uuid}/reviews/{review_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

review_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the customer/reviewer. Example : "My Review" Example: nihil

message   string  optional  

The message of the review. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: consectetur

rate   string   

The rate of the review ranging from 0-5. Example : 5 Example: ut

photo   file  optional  

The file photo of the review..jpg, .jpeg, .png Example: /tmp/phpfhG7iR

external_photo_url   string  optional  

An external url of an image as review/photo. Example: http://www.jast.com/

position   integer  optional  

The the position of the review. Example : 2 Example: 18

company_location_uuid   uuid  optional  

The company location to be associated to the review. Leaving empty/blank means visible to all company locations. Example: f7385aa8-02f2-3bd0-8644-56e31b893e48

Patch Index

requires authentication

Performs specific updates for review ranking

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews"
);

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

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

Request      

PATCH api/v1/companies/{company_uuid}/reviews

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

review_ranking_list   string  optional  

string[] A dictionary of uuids with uuid as key and rank as the value. Example : {"69e56cdf-cea8-4356-b35d-58d610aba886" : 1, "9c578b77-916a-4620-a246-fa951f422912" : 2} Example: ut

Patch

requires authentication

Patch a company review.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"esse\",
    \"message\": \"saepe\",
    \"rate\": \"assumenda\",
    \"external_photo_url\": \"http:\\/\\/www.lueilwitz.com\\/debitis-dolor-omnis-esse-voluptatum-et.html\",
    \"position\": 19,
    \"company_location_uuid\": \"9d8d3bcb-24ce-3942-9876-417c492cc89a\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'esse',
            'message' => 'saepe',
            'rate' => 'assumenda',
            'external_photo_url' => 'http://www.lueilwitz.com/debitis-dolor-omnis-esse-voluptatum-et.html',
            'position' => 19,
            'company_location_uuid' => '9d8d3bcb-24ce-3942-9876-417c492cc89a',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews/1"
);

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

let body = {
    "name": "esse",
    "message": "saepe",
    "rate": "assumenda",
    "external_photo_url": "http:\/\/www.lueilwitz.com\/debitis-dolor-omnis-esse-voluptatum-et.html",
    "position": 19,
    "company_location_uuid": "9d8d3bcb-24ce-3942-9876-417c492cc89a"
};

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

Request      

PATCH api/v1/companies/{company_uuid}/reviews/{review_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

review_uuid   integer   

Example: 1

Body Parameters

name   string  optional  

The name of the customer/reviewer. Example : "My Review" Example: esse

message   string  optional  

The message of the review. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: saepe

rate   string  optional  

The rate of the review ranging from 0-5. Example : 5 Example: assumenda

external_photo_url   string  optional  

An external url of an image as review/photo. Example: http://www.lueilwitz.com/debitis-dolor-omnis-esse-voluptatum-et.html

position   integer  optional  

The the position of the review. Example : 2 Example: 19

company_location_uuid   uuid  optional  

The company location to be associated to the review. Leaving empty/blank means visible to all company locations. Example: 9d8d3bcb-24ce-3942-9876-417c492cc89a

Delete

requires authentication

Delete a review.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/reviews/1"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/reviews/{review_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

review_uuid   integer   

Example: 1

Form Field

API for Form field

List

requires authentication

Shows the list of form fields with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/forms/{form_uuid}/fields

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

page   integer  optional  

The page number. Example : 1 Example: 14

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 2

sort_by   string  optional  

The column name. Example : name Example: et

sort_order   string  optional  

The order in which you want your records. Example : asc Example: in

search   string  optional  

The general search, it will find matching string. Example : "Quality Assurance" Example: alias

Show

requires authentication

Show a single form field.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/6d2f162c-47a5-3c3a-95c2-9d364c5d6d2e" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/6d2f162c-47a5-3c3a-95c2-9d364c5d6d2e';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/6d2f162c-47a5-3c3a-95c2-9d364c5d6d2e"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/forms/{form_uuid}/fields/{formField_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

formField_uuid   string   

Example: 6d2f162c-47a5-3c3a-95c2-9d364c5d6d2e

Store

requires authentication

Store a newly created formField.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"label\": \"placeat\",
    \"input_type\": \"beatae\",
    \"default_value\": \"doloremque\",
    \"is_required\": true,
    \"is_conditional\": true,
    \"has_help_guide\": true,
    \"conditional_value\": \"eum\",
    \"help_guide\": \"quia\",
    \"position\": 6
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'label' => 'placeat',
            'input_type' => 'beatae',
            'default_value' => 'doloremque',
            'is_required' => true,
            'is_conditional' => true,
            'has_help_guide' => true,
            'conditional_value' => 'eum',
            'help_guide' => 'quia',
            'position' => 6,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields"
);

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

let body = {
    "label": "placeat",
    "input_type": "beatae",
    "default_value": "doloremque",
    "is_required": true,
    "is_conditional": true,
    "has_help_guide": true,
    "conditional_value": "eum",
    "help_guide": "quia",
    "position": 6
};

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

Request      

POST api/v1/companies/{company_uuid}/forms/{form_uuid}/fields

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

Body Parameters

label   string   

The label of the form field. Example : "Are you satisfied with the communication from our technician?" Example: placeat

input_type   string   

The label of the form field. Example : "MULTI_SELECT" Example: beatae

default_value   string  optional  

The label of the form field. Example : "[1,2,3,4,5]" Example: doloremque

is_required   boolean  optional  

The label of the form field. Example : true Example: true

is_conditional   boolean  optional  

The label of the form field. Example : true Example: true

has_help_guide   boolean  optional  

The label of the form field. Example : true Example: true

conditional_value   text  optional  

The label of the form field. Example : {"condition1":"condition"} Example: eum

help_guide   string  optional  

text The label of the form field. Example : "This a help guide for communication from our technicians." Example: quia

position   integer  optional  

The position of the form field. Example : 1 Example: 6

Update

requires authentication

Update a formfield.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/1692d657-2277-3f28-b462-ed38c14ef1a0" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"label\": \"ratione\",
    \"input_type\": \"dolor\",
    \"default_value\": \"unde\",
    \"is_required\": false,
    \"is_conditional\": true,
    \"has_help_guide\": true,
    \"conditional_value\": \"unde\",
    \"help_guide\": \"odio\",
    \"position\": 13
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/1692d657-2277-3f28-b462-ed38c14ef1a0';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'label' => 'ratione',
            'input_type' => 'dolor',
            'default_value' => 'unde',
            'is_required' => false,
            'is_conditional' => true,
            'has_help_guide' => true,
            'conditional_value' => 'unde',
            'help_guide' => 'odio',
            'position' => 13,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/1692d657-2277-3f28-b462-ed38c14ef1a0"
);

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

let body = {
    "label": "ratione",
    "input_type": "dolor",
    "default_value": "unde",
    "is_required": false,
    "is_conditional": true,
    "has_help_guide": true,
    "conditional_value": "unde",
    "help_guide": "odio",
    "position": 13
};

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

Request      

PUT api/v1/companies/{company_uuid}/forms/{form_uuid}/fields/{formField_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

formField_uuid   string   

Example: 1692d657-2277-3f28-b462-ed38c14ef1a0

Body Parameters

label   string   

The label of the form field. Example : "Are you satisfied with the communication from our technician?" Example: ratione

input_type   string   

The label of the form field. Example : "MULTI_SELECT" Example: dolor

default_value   string  optional  

The label of the form field. Example : "[1,2,3,4,5]" Example: unde

is_required   boolean  optional  

The label of the form field. Example : true Example: false

is_conditional   boolean  optional  

The label of the form field. Example : true Example: true

has_help_guide   boolean  optional  

The label of the form field. Example : true Example: true

conditional_value   text  optional  

The label of the form field. Example : {"condition1":"condition"} Example: unde

help_guide   string  optional  

text The label of the form field. Example : "This a help guide for communication from our technicians." Example: odio

position   integer  optional  

The position of the form field. Example : 1 Example: 13

Update

requires authentication

Update a formfield.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/4f5c6dd0-7018-3063-ae6d-6f61601841d2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"label\": \"alias\",
    \"input_type\": \"ducimus\",
    \"default_value\": \"aperiam\",
    \"is_required\": true,
    \"is_conditional\": false,
    \"has_help_guide\": false,
    \"conditional_value\": \"ut\",
    \"help_guide\": \"iusto\",
    \"position\": 15
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/4f5c6dd0-7018-3063-ae6d-6f61601841d2';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'label' => 'alias',
            'input_type' => 'ducimus',
            'default_value' => 'aperiam',
            'is_required' => true,
            'is_conditional' => false,
            'has_help_guide' => false,
            'conditional_value' => 'ut',
            'help_guide' => 'iusto',
            'position' => 15,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/4f5c6dd0-7018-3063-ae6d-6f61601841d2"
);

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

let body = {
    "label": "alias",
    "input_type": "ducimus",
    "default_value": "aperiam",
    "is_required": true,
    "is_conditional": false,
    "has_help_guide": false,
    "conditional_value": "ut",
    "help_guide": "iusto",
    "position": 15
};

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

Request      

POST api/v1/companies/{company_uuid}/forms/{form_uuid}/fields/{formField_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

formField_uuid   string   

Example: 4f5c6dd0-7018-3063-ae6d-6f61601841d2

Body Parameters

label   string   

The label of the form field. Example : "Are you satisfied with the communication from our technician?" Example: alias

input_type   string   

The label of the form field. Example : "MULTI_SELECT" Example: ducimus

default_value   string  optional  

The label of the form field. Example : "[1,2,3,4,5]" Example: aperiam

is_required   boolean  optional  

The label of the form field. Example : true Example: true

is_conditional   boolean  optional  

The label of the form field. Example : true Example: false

has_help_guide   boolean  optional  

The label of the form field. Example : true Example: false

conditional_value   text  optional  

The label of the form field. Example : {"condition1":"condition"} Example: ut

help_guide   string  optional  

text The label of the form field. Example : "This a help guide for communication from our technicians." Example: iusto

position   integer  optional  

The position of the form field. Example : 1 Example: 15

Patch

requires authentication

Patch a company form field.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/e05c0ba7-46b3-3086-b044-b82b6d165bb6" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"label\": \"aliquam\",
    \"input_type\": \"illum\",
    \"default_value\": \"repellendus\",
    \"is_required\": true,
    \"is_conditional\": true,
    \"has_help_guide\": true,
    \"conditional_value\": \"mollitia\",
    \"help_guide\": \"sed\",
    \"position\": 8
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/e05c0ba7-46b3-3086-b044-b82b6d165bb6';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'label' => 'aliquam',
            'input_type' => 'illum',
            'default_value' => 'repellendus',
            'is_required' => true,
            'is_conditional' => true,
            'has_help_guide' => true,
            'conditional_value' => 'mollitia',
            'help_guide' => 'sed',
            'position' => 8,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/e05c0ba7-46b3-3086-b044-b82b6d165bb6"
);

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

let body = {
    "label": "aliquam",
    "input_type": "illum",
    "default_value": "repellendus",
    "is_required": true,
    "is_conditional": true,
    "has_help_guide": true,
    "conditional_value": "mollitia",
    "help_guide": "sed",
    "position": 8
};

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

Request      

PATCH api/v1/companies/{company_uuid}/forms/{form_uuid}/fields/{formField_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

formField_uuid   string   

Example: e05c0ba7-46b3-3086-b044-b82b6d165bb6

Body Parameters

label   string  optional  

The label of the form field. Example : "Are you satisfied with the communication from our technician?" Example: aliquam

input_type   string  optional  

The label of the form field. Example : "MULTI_SELECT" Example: illum

default_value   string  optional  

The label of the form field. Example : "[1,2,3,4,5]" Example: repellendus

is_required   boolean  optional  

The label of the form field. Example : true Example: true

is_conditional   boolean  optional  

The label of the form field. Example : true Example: true

has_help_guide   boolean  optional  

The label of the form field. Example : true Example: true

conditional_value   text  optional  

The label of the form field. Example : {"condition1":"condition"} Example: mollitia

help_guide   string  optional  

text The label of the form field. Example : "This a help guide for communication from our technicians." Example: sed

position   integer  optional  

The position of the form field. Example : 1 Example: 8

Delete

requires authentication

Delete a form field.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/e088a3c6-58e1-3287-83ca-4886427d2d02" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/e088a3c6-58e1-3287-83ca-4886427d2d02';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/fields/e088a3c6-58e1-3287-83ca-4886427d2d02"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/forms/{form_uuid}/fields/{formField_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

formField_uuid   string   

Example: e088a3c6-58e1-3287-83ca-4886427d2d02

App Data

API for app data such as: countries, states, roles, statuses, etc.

Application Settings.

requires authentication

Show the list of application data: [roles, company_locations, statuses, countries[states], client_version]

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/app-data" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/app-data';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/app-data"
);

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

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

Request      

GET api/v1/app-data

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Customer Contacts

API for customer contacts

Update

requires authentication

Update customer contacts

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f/customer-contacts" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"contacts[]\": null,
    \"delete_contacts[]\": null
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f/customer-contacts';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'contacts[]' => null,
            'delete_contacts[]' => null,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f/customer-contacts"
);

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

let body = {
    "contacts[]": null,
    "delete_contacts[]": null
};

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

Request      

PUT api/v1/customers/{customer_uuid}/customer-contacts

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

customer_uuid   string  optional  

uuid required The UUID of the customer that is to be updated. Example: 3245d634-24fd-11ec-accd-e397aec85c7f

Body Parameters

contacts[]   string[]  optional  

of contacts.

delete_contacts[]   string[]  optional  

of contacts.uuid to be deleted.

Service Plan Custom Field

API for Service Plan Custom Field

List

requires authentication

Shows the list of Service Plan Custom Fields with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields"
);

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

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

Request      

GET api/v1/service-plans/{servicePlan_uuid}/custom-fields

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

page   integer  optional  

The page number. Example : 1 Example: 20

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 13

sort_by   string  optional  

The column name. Example : name Example: laboriosam

sort_order   string  optional  

The order in which you want your records. Example : asc Example: quaerat

search   string  optional  

The general search, it will find matching string. Example : home Example: laudantium

Create (Single/Multiple)

requires authentication

Store a newly created Service Plan Custom Field. For multiple creation, the @bodyParameter will be an array of a single @bodyParameter

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"label\": \"First Name\",
    \"input_type\": \"TEXT\",
    \"default_value\": \"\\\"\\\"\",
    \"combine_input_value_collection\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'label' => 'First Name',
            'input_type' => 'TEXT',
            'default_value' => '""',
            'combine_input_value_collection' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields"
);

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

let body = {
    "label": "First Name",
    "input_type": "TEXT",
    "default_value": "\"\"",
    "combine_input_value_collection": true
};

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

Request      

POST api/v1/service-plans/{servicePlan_uuid}/custom-fields

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

Body Parameters

label   string   

The label Service Plan Custom Field. Example: First Name

input_type   string   

The field type of the custom field. Example: TEXT

default_value   string  optional  

optional The default value of the custom field. Example: ""

combine_input_value_collection   boolean  optional  

optional The option to combine custom fields by label. Example: true

Update (Single/Multiple)

requires authentication

Modify the specified Service Plan Custom Field. For Multiple update, @bodyparameter will be an array of the Single @bodyParameter (if uuid is included then perform an update; else, create new record).

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"custom_fields\": \"ypixgdofcc\",
    \"save_service_plan_as\": \"SERVICE_PLAN_DRAFT\",
    \"label\": \"First Name\",
    \"input_type\": \"TEXT\",
    \"default_value\": \"\\\"\\\"\",
    \"combine_input_value_collection\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'custom_fields' => 'ypixgdofcc',
            'save_service_plan_as' => 'SERVICE_PLAN_DRAFT',
            'label' => 'First Name',
            'input_type' => 'TEXT',
            'default_value' => '""',
            'combine_input_value_collection' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields"
);

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

let body = {
    "custom_fields": "ypixgdofcc",
    "save_service_plan_as": "SERVICE_PLAN_DRAFT",
    "label": "First Name",
    "input_type": "TEXT",
    "default_value": "\"\"",
    "combine_input_value_collection": true
};

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

Request      

PUT api/v1/service-plans/{servicePlan_uuid}/custom-fields

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

Body Parameters

custom_fields   string[]  optional  

Must have at least 0 items. Must not have more than 150 items. Example: ypixgdofcc

label   string   

Must not be greater than 191 characters. Example: ablcgssczsn

input_type   string  optional  
combine_input_value_collection   boolean  optional  

Example: true

save_service_plan_as   string  optional  

Example: SERVICE_PLAN_DRAFT

Must be one of:
  • SERVICE_PLAN_DRAFT
  • SERVICE_PLAN_ACTIVE
  • SERVICE_PLAN_ARCHIVED
label   string   

The label Service Plan Custom Field. Example: First Name

input_type   string   

The field type of the custom field. Example: TEXT

default_value   string  optional  

optional The default value of the custom field. Example: ""

combine_input_value_collection   boolean  optional  

optional The option to combine custom fields by label. Example: true

Get

requires authentication

Display the specified Service Plan Custom Field.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields/a66a796a-d987-39cb-8340-ba850ea4f199" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields/a66a796a-d987-39cb-8340-ba850ea4f199';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields/a66a796a-d987-39cb-8340-ba850ea4f199"
);

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

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

Request      

GET api/v1/service-plans/{servicePlan_uuid}/custom-fields/{servicePlanCustomField_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

servicePlanCustomField_uuid   string   

Example: a66a796a-d987-39cb-8340-ba850ea4f199

Update (Single/Multiple)

requires authentication

Modify the specified Service Plan Custom Field. For Multiple update, @bodyparameter will be an array of the Single @bodyParameter (if uuid is included then perform an update; else, create new record).

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields/3fbf6566-ee68-3bc7-8860-6991fc0921cf" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"custom_fields\": \"bhpznpzxqrlmkg\",
    \"save_service_plan_as\": \"SERVICE_PLAN_DRAFT\",
    \"label\": \"First Name\",
    \"input_type\": \"TEXT\",
    \"default_value\": \"\\\"\\\"\",
    \"combine_input_value_collection\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields/3fbf6566-ee68-3bc7-8860-6991fc0921cf';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'custom_fields' => 'bhpznpzxqrlmkg',
            'save_service_plan_as' => 'SERVICE_PLAN_DRAFT',
            'label' => 'First Name',
            'input_type' => 'TEXT',
            'default_value' => '""',
            'combine_input_value_collection' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields/3fbf6566-ee68-3bc7-8860-6991fc0921cf"
);

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

let body = {
    "custom_fields": "bhpznpzxqrlmkg",
    "save_service_plan_as": "SERVICE_PLAN_DRAFT",
    "label": "First Name",
    "input_type": "TEXT",
    "default_value": "\"\"",
    "combine_input_value_collection": true
};

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

Request      

PUT api/v1/service-plans/{servicePlan_uuid}/custom-fields/{servicePlanCustomField_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

servicePlanCustomField_uuid   string   

Example: 3fbf6566-ee68-3bc7-8860-6991fc0921cf

Body Parameters

custom_fields   string[]  optional  

Must have at least 0 items. Must not have more than 150 items. Example: bhpznpzxqrlmkg

label   string   

Must not be greater than 191 characters. Example: qoaqnyatydfrowhd

input_type   string  optional  
combine_input_value_collection   boolean  optional  

Example: true

save_service_plan_as   string  optional  

Example: SERVICE_PLAN_DRAFT

Must be one of:
  • SERVICE_PLAN_DRAFT
  • SERVICE_PLAN_ACTIVE
  • SERVICE_PLAN_ARCHIVED
label   string   

The label Service Plan Custom Field. Example: First Name

input_type   string   

The field type of the custom field. Example: TEXT

default_value   string  optional  

optional The default value of the custom field. Example: ""

combine_input_value_collection   boolean  optional  

optional The option to combine custom fields by label. Example: true

Patch

requires authentication

Perform patches for the specified Service Plan Custom Field.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields/c44572dc-06e1-3473-9a45-525de1cc2347" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"label\": \"First Name\",
    \"input_type\": \"TEXT\",
    \"default_value\": \"\\\"\\\"\",
    \"combine_input_value_collection\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields/c44572dc-06e1-3473-9a45-525de1cc2347';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'label' => 'First Name',
            'input_type' => 'TEXT',
            'default_value' => '""',
            'combine_input_value_collection' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields/c44572dc-06e1-3473-9a45-525de1cc2347"
);

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

let body = {
    "label": "First Name",
    "input_type": "TEXT",
    "default_value": "\"\"",
    "combine_input_value_collection": true
};

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

Request      

PATCH api/v1/service-plans/{servicePlan_uuid}/custom-fields/{servicePlanCustomField_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

servicePlanCustomField_uuid   string   

Example: c44572dc-06e1-3473-9a45-525de1cc2347

Body Parameters

label   string  optional  

The label Service Plan Custom Field. Example: First Name

input_type   string  optional  

The field type of the custom field. Example: TEXT

default_value   string  optional  

optional The default value of the custom field. Example: ""

combine_input_value_collection   boolean  optional  

optional The option to combine custom fields by label. Example: true

Delete

requires authentication

Remove the specified Service Plan Custom Field.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields/b369e223-b37a-3eb4-834a-60a146cea45f" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields/b369e223-b37a-3eb4-834a-60a146cea45f';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/custom-fields/b369e223-b37a-3eb4-834a-60a146cea45f"
);

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

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

Request      

DELETE api/v1/service-plans/{servicePlan_uuid}/custom-fields/{servicePlanCustomField_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

servicePlanCustomField_uuid   string   

Example: b369e223-b37a-3eb4-834a-60a146cea45f

Media Tag

API for Media Tag

List

requires authentication

Shows the list of media tag with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/media-tags" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-tags';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-tags"
);

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

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

Request      

GET api/v1/media-tags

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 3

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 18

sort_by   string  optional  

The column name. Example : name Example: quod

sort_order   string  optional  

The order in which you want your records. Example : asc Example: ipsa

search   string  optional  

The general search, it will find matching string. Example : home Example: consequatur

Show

requires authentication

Show a single media tag

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/media-tags/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-tags/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-tags/1"
);

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

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

Request      

GET api/v1/media-tags/{mediaTag_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaTag_uuid   integer   

Example: 1

Store

requires authentication

Upload a media tag

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/media-tags" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"quis\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-tags';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'quis',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-tags"
);

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

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

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

Request      

POST api/v1/media-tags

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

name   string  optional  

The name of the file. Example : Tag 1 Example: quis

Update

requires authentication

Update a media tag.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/media-tags/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"modi\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-tags/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'modi',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-tags/1"
);

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

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

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

Request      

PUT api/v1/media-tags/{mediaTag_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaTag_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the media tag. Example : "My media tag" Example: modi

Patch

requires authentication

Patch a media tag.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/media-tags/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"occaecati\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-tags/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'occaecati',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-tags/1"
);

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

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

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

Request      

PATCH api/v1/media-tags/{mediaTag_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaTag_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the media tag. Example : "My media tag" Example: occaecati

Delete

requires authentication

Delete a media tag.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/media-tags/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-tags/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-tags/1"
);

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

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

Request      

DELETE api/v1/media-tags/{mediaTag_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaTag_uuid   integer   

Example: 1

Property Locations

API for Property Locations

List

requires authentication

Shows the list of property locations with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/property-locations

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 13

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 4

sort_by   string  optional  

The column name. Example : name Example: aut

sort_order   string  optional  

The order in which you want your records. Example : asc Example: fuga

search   string  optional  

The general search, it will find matching string. Example : home Example: nisi

Show

requires authentication

Show a single property location.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations/1"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/property-locations/{propertyLocation_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

propertyLocation_uuid   integer   

Example: 1

Store

requires authentication

Store a newly created property location.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"laboriosam\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'laboriosam',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations"
);

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

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

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

Request      

POST api/v1/companies/{company_uuid}/property-locations

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the property location. Example : "Living Room" Example: laboriosam

Update

requires authentication

Update a property location.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"rerum\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'rerum',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations/1"
);

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

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

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

Request      

PUT api/v1/companies/{company_uuid}/property-locations/{propertyLocation_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

propertyLocation_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the property location. Example : "Living Room Updated" Example: rerum

Patch

requires authentication

Patch a company property location.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"sit\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'sit',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations/1"
);

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

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

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

Request      

PATCH api/v1/companies/{company_uuid}/property-locations/{propertyLocation_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

propertyLocation_uuid   integer   

Example: 1

Body Parameters

name   string  optional  

The name of the property location. Example : "Living Room Patched" Example: sit

Delete

requires authentication

Delete a property location.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/property-locations/1"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/property-locations/{propertyLocation_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

propertyLocation_uuid   integer   

Example: 1

State

API for state details

List / Fetch

Shows the list of state or fetch single record using uuid.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/countries/510ba169-48b6-3659-88fb-3bcc711dfd8d/states/5262ea51-350b-307b-9a45-503126fc0fee" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"country_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"country_state_uuid\": \"ed20f1c0-2749-11ec-85fa-a791bcbdc50d\",
    \"name\": \"Queen Creek\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/countries/510ba169-48b6-3659-88fb-3bcc711dfd8d/states/5262ea51-350b-307b-9a45-503126fc0fee';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'country_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'country_state_uuid' => 'ed20f1c0-2749-11ec-85fa-a791bcbdc50d',
            'name' => 'Queen Creek',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/countries/510ba169-48b6-3659-88fb-3bcc711dfd8d/states/5262ea51-350b-307b-9a45-503126fc0fee"
);

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

let body = {
    "country_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "country_state_uuid": "ed20f1c0-2749-11ec-85fa-a791bcbdc50d",
    "name": "Queen Creek"
};

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

Request      

GET api/v1/countries/{countryUuid}/states/{countryStateUuid}

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

countryUuid   string   

Example: 510ba169-48b6-3659-88fb-3bcc711dfd8d

countryStateUuid   string   

Example: 5262ea51-350b-307b-9a45-503126fc0fee

Body Parameters

country_uuid   string  optional  

optional The country uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

country_state_uuid   string  optional  

optional The state uuid. Example: ed20f1c0-2749-11ec-85fa-a791bcbdc50d

name   string  optional  

optional The state name. Example: Queen Creek

Company Tax

API for Company Tax

List

requires authentication

Shows the list of taxes with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/taxes

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 11

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 11

sort_by   string  optional  

The column name. Example : name Example: velit

sort_order   string  optional  

The order in which you want your records. Example : asc Example: consequatur

search   string  optional  

The general search, it will find matching string (name, postal_code, cities). Example : home Example: labore

country_uuid   string  optional  

The UUID of country. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: e48e0837-e5e6-346a-92fa-012987f13ca5

country_state_uuids   integer  optional  

string[] The UUID of country state. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 11

is_compound   string  optional  

boolean To filter by is_compound flag. Example : true Example: eos

Patch Index

requires authentication

Performs specific updates for tax settings

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes"
);

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

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

Request      

PATCH api/v1/companies/{company_uuid}/taxes

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

tax_ranking_list   string  optional  

string[] A dictionary of uuids with uuid as key and rank as the value. Example : {"69e56cdf-cea8-4356-b35d-58d610aba886" : 1, "9c578b77-916a-4620-a246-fa951f422912" : 2} Example: rerum

Show

requires authentication

Show a single tax.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes/46a50f07-246f-3df1-9f8f-e76b59b849cb" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes/46a50f07-246f-3df1-9f8f-e76b59b849cb';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes/46a50f07-246f-3df1-9f8f-e76b59b849cb"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/taxes/{companyTax_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyTax_uuid   string   

Example: 46a50f07-246f-3df1-9f8f-e76b59b849cb

Store

requires authentication

Store a newly created tax.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"country_uuid\": \"a755472c-2ae1-3d4a-8d54-90a723070a81\",
    \"country_state_uuids\": [
        \"voluptatibus\"
    ],
    \"name\": \"provident\",
    \"postal_codes\": 85410,
    \"cities\": \"Queen Creek\",
    \"rate\": \"12.0000\",
    \"is_compound\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'country_uuid' => 'a755472c-2ae1-3d4a-8d54-90a723070a81',
            'country_state_uuids' => [
                'voluptatibus',
            ],
            'name' => 'provident',
            'postal_codes' => 85410,
            'cities' => 'Queen Creek',
            'rate' => '12.0000',
            'is_compound' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes"
);

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

let body = {
    "country_uuid": "a755472c-2ae1-3d4a-8d54-90a723070a81",
    "country_state_uuids": [
        "voluptatibus"
    ],
    "name": "provident",
    "postal_codes": 85410,
    "cities": "Queen Creek",
    "rate": "12.0000",
    "is_compound": true
};

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

Request      

POST api/v1/companies/{company_uuid}/taxes

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

country_uuid   string   

The UUID of a country. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: a755472c-2ae1-3d4a-8d54-90a723070a81

country_state_uuids   string[]   

An array of country state UUID. Example : ["815d3d9c-f371-3781-8456-7e6954b5b0f5", "815d3d9c-f371-3781-8456-7e6954b5b0f2"]

name   string   

The name of the tax. Example : Pest Route Initial Proposal Example: provident

postal_codes   string[]  optional  

optional The postal code of the company. Example: 85410

cities   string  optional  

required[] The company city name. Example: Queen Creek

rate   decimal   

The tax rate. Example: 12.0000

is_compound   boolean   

A flag that indicate if the tax is a compound. Example: true

Update

requires authentication

Update a tax.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes/0aeb6c97-609f-371d-9686-8b6b07ddee7a" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"country_uuid\": \"da7a301e-7e07-3d9f-8ab0-5dcb11247d92\",
    \"country_state_uuids\": [
        \"quo\"
    ],
    \"name\": \"modi\",
    \"postal_codes\": \"85410\",
    \"cities\": \"Queen Creek\",
    \"rate\": \"12.0000\",
    \"is_compound\": true,
    \"rank\": 1
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes/0aeb6c97-609f-371d-9686-8b6b07ddee7a';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'country_uuid' => 'da7a301e-7e07-3d9f-8ab0-5dcb11247d92',
            'country_state_uuids' => [
                'quo',
            ],
            'name' => 'modi',
            'postal_codes' => '85410',
            'cities' => 'Queen Creek',
            'rate' => '12.0000',
            'is_compound' => true,
            'rank' => 1,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes/0aeb6c97-609f-371d-9686-8b6b07ddee7a"
);

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

let body = {
    "country_uuid": "da7a301e-7e07-3d9f-8ab0-5dcb11247d92",
    "country_state_uuids": [
        "quo"
    ],
    "name": "modi",
    "postal_codes": "85410",
    "cities": "Queen Creek",
    "rate": "12.0000",
    "is_compound": true,
    "rank": 1
};

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

Request      

PUT api/v1/companies/{company_uuid}/taxes/{companyTax_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyTax_uuid   string   

Example: 0aeb6c97-609f-371d-9686-8b6b07ddee7a

Body Parameters

country_uuid   string   

The UUID of a country. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: da7a301e-7e07-3d9f-8ab0-5dcb11247d92

country_state_uuids   string[]   

The UUID of a country state. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5"

name   string   

The name of the tax. Example : Pest Route Initial Proposal Example: modi

postal_codes   string  optional  

optional The postal code of the company. Example: 85410

cities   string   

The company city name. Example: Queen Creek

rate   decimal   

The tax rate. Example: 12.0000

is_compound   boolean   

A flag that indicate if the tax is a compound. Example: true

rank   integer  optional  

The rank/order number of tax in a company. Example: 1

Patch

requires authentication

Patch a tax.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes/e5db137f-44da-3fb8-9aed-98d312eb30a1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"country_uuid\": \"e7563335-f529-3bca-b4d7-a9479baae088\",
    \"country_state_uuids\": [
        \"voluptas\"
    ],
    \"name\": \"perferendis\",
    \"postal_codes\": \"85410\",
    \"cities\": \"Queen Creek\",
    \"rate\": \"12.0000\",
    \"is_compound\": true,
    \"rank\": 1
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes/e5db137f-44da-3fb8-9aed-98d312eb30a1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'country_uuid' => 'e7563335-f529-3bca-b4d7-a9479baae088',
            'country_state_uuids' => [
                'voluptas',
            ],
            'name' => 'perferendis',
            'postal_codes' => '85410',
            'cities' => 'Queen Creek',
            'rate' => '12.0000',
            'is_compound' => true,
            'rank' => 1,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes/e5db137f-44da-3fb8-9aed-98d312eb30a1"
);

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

let body = {
    "country_uuid": "e7563335-f529-3bca-b4d7-a9479baae088",
    "country_state_uuids": [
        "voluptas"
    ],
    "name": "perferendis",
    "postal_codes": "85410",
    "cities": "Queen Creek",
    "rate": "12.0000",
    "is_compound": true,
    "rank": 1
};

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

Request      

PATCH api/v1/companies/{company_uuid}/taxes/{companyTax_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyTax_uuid   string   

Example: e5db137f-44da-3fb8-9aed-98d312eb30a1

Body Parameters

country_uuid   string  optional  

optional The UUID of a country. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: e7563335-f529-3bca-b4d7-a9479baae088

country_state_uuids   string[]  optional  

optional The UUID of a country state. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5"

name   string  optional  

optional The name of the tax. Example : Pest Route Initial Proposal Example: perferendis

postal_codes   string  optional  

optional The postal code of the company. Example: 85410

cities   string  optional  

optional The company city name. Example: Queen Creek

rate   decimal  optional  

optional The tax rate. Example: 12.0000

is_compound   boolean  optional  

optional A flag that indicate if the tax is a compound. Example: true

rank   integer  optional  

The rank/order number of tax in a company. Example: 1

Delete

requires authentication

Delete a tax.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes/df09de09-7861-3c70-8b79-a5e21e95f022" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes/df09de09-7861-3c70-8b79-a5e21e95f022';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/taxes/df09de09-7861-3c70-8b79-a5e21e95f022"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/taxes/{companyTax_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyTax_uuid   string   

Example: df09de09-7861-3c70-8b79-a5e21e95f022

Company Location

API for company locations

List

requires authentication

Shows the list of locations with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/locations';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/locations

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 6

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 11

sort_by   string  optional  

The column name. Example : name Example: qui

sort_order   string  optional  

The order in which you want your records. Example : asc Example: necessitatibus

search   string  optional  

The general search, it will find matching string. Example : home Example: error

has_service_plans   string  optional  

boolean The locations which has service plans. Example : true Example: laborum

Show

requires authentication

Shows the detail of a specific company location.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/11313874-2664-32d4-8466-78524e7b2567" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"withTemplates\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/11313874-2664-32d4-8466-78524e7b2567';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'withTemplates' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/11313874-2664-32d4-8466-78524e7b2567"
);

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

let body = {
    "withTemplates": true
};

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

Request      

GET api/v1/companies/{company_uuid}/locations/{companyLocation_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyLocation_uuid   string   

Example: 11313874-2664-32d4-8466-78524e7b2567

companyUUID   string   

The company uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

companyLocationUUID   string   

The company uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

withTemplates   boolean  optional  

optional Whether return templates attached to company location. Example: true

Create

requires authentication

This endpoint lets user to create single record using uuid.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Phoenix Metro Area\",
    \"description\": \"We do amazing things here.\",
    \"phone\": \"5554443333\",
    \"email\": \"hello@smarterlaunch.com\",
    \"address1\": \"\'123 Smarter Launch Way\'\",
    \"address2\": \"\'Suite 101\'\",
    \"city\": \"Queen Creek\",
    \"country_state_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"country_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"postal_code\": \"85410\",
    \"latitude\": \"23.0396\",
    \"longitude\": \"72.566\",
    \"enable_overrides\": true,
    \"license_number\": \"lc-123456\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/locations';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Phoenix Metro Area',
            'description' => 'We do amazing things here.',
            'phone' => '5554443333',
            'email' => 'hello@smarterlaunch.com',
            'address1' => '\'123 Smarter Launch Way\'',
            'address2' => '\'Suite 101\'',
            'city' => 'Queen Creek',
            'country_state_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'country_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'postal_code' => '85410',
            'latitude' => '23.0396',
            'longitude' => '72.566',
            'enable_overrides' => true,
            'license_number' => 'lc-123456',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations"
);

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

let body = {
    "name": "Phoenix Metro Area",
    "description": "We do amazing things here.",
    "phone": "5554443333",
    "email": "hello@smarterlaunch.com",
    "address1": "'123 Smarter Launch Way'",
    "address2": "'Suite 101'",
    "city": "Queen Creek",
    "country_state_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "country_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "postal_code": "85410",
    "latitude": "23.0396",
    "longitude": "72.566",
    "enable_overrides": true,
    "license_number": "lc-123456"
};

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

Request      

POST api/v1/companies/{company_uuid}/locations

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the location. Example: Phoenix Metro Area

description   string  optional  

optional The description of the location. Example: We do amazing things here.

phone   string  optional  

optional The last name of the location. Example: 5554443333

email   string  optional  

optional The email of the location. Example: hello@smarterlaunch.com

address1   string  optional  

optional The address of the company. Example: '123 Smarter Launch Way'

address2   string  optional  

optional The address of the company. Example: 'Suite 101'

city   string  optional  

optional The company city name. Example: Queen Creek

country_state_uuid   string  optional  

optional The company state uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

country_uuid   string  optional  

optional The company country uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

postal_code   string  optional  

optional The postal code of the company. Example: 85410

latitude   string  optional  

optional The latitude of the company. Example: 23.0396

longitude   string  optional  

optional The longitude of the company. Example: 72.566

enable_overrides   boolean  optional  

optional. Example: true

license_number   string  optional  

optional. Example: lc-123456

Update All

requires authentication

This endpoint lets user to update multiple record using uuids.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/updateAll" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/updateAll';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/updateAll"
);

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

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

Request      

PUT api/v1/companies/{company_uuid}/locations/updateAll

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyUuid   string   

The uuid id of the company. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

*   object  optional  
name   string   

The name of the location. Example: Phoenix Metro Area

description   string  optional  

optional The description of the location. Example: We do amazing things here.

phone   string  optional  

optional The last name of the location. Example: 5554443333

email   string  optional  

optional The email of the location. Example: hello@smarterlaunch.com

address1   string  optional  

optional The address of the company. Example: '123 Smarter Launch Way'

address2   string  optional  

optional The address of the company. Example: 'Suite 101'

city   string  optional  

optional The company city name. Example: Queen Creek

country_state_uuid   string  optional  

optional The company state uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

country_uuid   string  optional  

optional The company country uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

postal_code   string  optional  

optional The postal code of the company. Example: 85410

latitude   string  optional  

optional The latitude of the company. Example: 23.0396

longitude   string  optional  

optional The longitude of the company. Example: 72.566

enable_overrides   boolean  optional  

optional. Example: true

Edit

requires authentication

This endpoint lets user to update single record using uuid (using PUT method).

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/4d7a6009-cd8a-3669-8dab-460428a815fc" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Phoenix Metro Area\",
    \"description\": \"We do amazing things here.\",
    \"phone\": \"5554443333\",
    \"email\": \"hello@smarterlaunch.com\",
    \"address1\": \"\'123 Smarter Launch Way\'\",
    \"address2\": \"\'Suite 101\'\",
    \"city\": \"Queen Creek\",
    \"country_state_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"country_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"postal_code\": \"85410\",
    \"latitude\": \"23.0396\",
    \"longitude\": \"72.566\",
    \"enable_overrides\": true,
    \"license_number\": \"lc-123456\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/4d7a6009-cd8a-3669-8dab-460428a815fc';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Phoenix Metro Area',
            'description' => 'We do amazing things here.',
            'phone' => '5554443333',
            'email' => 'hello@smarterlaunch.com',
            'address1' => '\'123 Smarter Launch Way\'',
            'address2' => '\'Suite 101\'',
            'city' => 'Queen Creek',
            'country_state_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'country_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'postal_code' => '85410',
            'latitude' => '23.0396',
            'longitude' => '72.566',
            'enable_overrides' => true,
            'license_number' => 'lc-123456',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/4d7a6009-cd8a-3669-8dab-460428a815fc"
);

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

let body = {
    "name": "Phoenix Metro Area",
    "description": "We do amazing things here.",
    "phone": "5554443333",
    "email": "hello@smarterlaunch.com",
    "address1": "'123 Smarter Launch Way'",
    "address2": "'Suite 101'",
    "city": "Queen Creek",
    "country_state_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "country_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "postal_code": "85410",
    "latitude": "23.0396",
    "longitude": "72.566",
    "enable_overrides": true,
    "license_number": "lc-123456"
};

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

Request      

PUT api/v1/companies/{company_uuid}/locations/{companyLocation_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyLocation_uuid   string   

Example: 4d7a6009-cd8a-3669-8dab-460428a815fc

companyUuid   string   

The uuid id of the company. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

companyLocationUuid   string   

The uuid id of the location. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

name   string   

The name of the location. Example: Phoenix Metro Area

description   string  optional  

optional The description of the location. Example: We do amazing things here.

phone   string  optional  

optional The last name of the location. Example: 5554443333

email   string  optional  

optional The email of the location. Example: hello@smarterlaunch.com

address1   string  optional  

optional The address of the company. Example: '123 Smarter Launch Way'

address2   string  optional  

optional The address of the company. Example: 'Suite 101'

city   string  optional  

optional The company city name. Example: Queen Creek

country_state_uuid   string  optional  

optional The company state uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

country_uuid   string  optional  

optional The company country uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

postal_code   string  optional  

optional The postal code of the company. Example: 85410

latitude   string  optional  

optional The latitude of the company. Example: 23.0396

longitude   string  optional  

optional The longitude of the company. Example: 72.566

enable_overrides   boolean  optional  

optional. Example: true

license_number   string  optional  

optional. Example: lc-123456

Update

requires authentication

This endpoint lets user to update single record using uuid.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/369cc46b-d6ff-38f0-9f47-fc9e02c54e3c" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Phoenix Metro Area\",
    \"description\": \"We do amazing things here.\",
    \"phone\": \"5554443333\",
    \"email\": \"hello@smarterlaunch.com\",
    \"address1\": \"\'123 Smarter Launch Way\'\",
    \"address2\": \"\'Suite 101\'\",
    \"city\": \"Queen Creek\",
    \"country_state_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"country_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"postal_code\": \"85410\",
    \"latitude\": \"23.0396\",
    \"longitude\": \"72.566\",
    \"enable_overrides\": true,
    \"license_number\": \"lc-123456\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/369cc46b-d6ff-38f0-9f47-fc9e02c54e3c';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Phoenix Metro Area',
            'description' => 'We do amazing things here.',
            'phone' => '5554443333',
            'email' => 'hello@smarterlaunch.com',
            'address1' => '\'123 Smarter Launch Way\'',
            'address2' => '\'Suite 101\'',
            'city' => 'Queen Creek',
            'country_state_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'country_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'postal_code' => '85410',
            'latitude' => '23.0396',
            'longitude' => '72.566',
            'enable_overrides' => true,
            'license_number' => 'lc-123456',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/369cc46b-d6ff-38f0-9f47-fc9e02c54e3c"
);

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

let body = {
    "name": "Phoenix Metro Area",
    "description": "We do amazing things here.",
    "phone": "5554443333",
    "email": "hello@smarterlaunch.com",
    "address1": "'123 Smarter Launch Way'",
    "address2": "'Suite 101'",
    "city": "Queen Creek",
    "country_state_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "country_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "postal_code": "85410",
    "latitude": "23.0396",
    "longitude": "72.566",
    "enable_overrides": true,
    "license_number": "lc-123456"
};

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

Request      

PATCH api/v1/companies/{company_uuid}/locations/{companyLocation_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyLocation_uuid   string   

Example: 369cc46b-d6ff-38f0-9f47-fc9e02c54e3c

companyUuid   string   

The uuid id of the company. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

companyLocationUuid   string   

The uuid id of the location. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

name   string   

The name of the location. Example: Phoenix Metro Area

description   string  optional  

optional The description of the location. Example: We do amazing things here.

phone   string  optional  

optional The last name of the location. Example: 5554443333

email   string  optional  

optional The email of the location. Example: hello@smarterlaunch.com

address1   string  optional  

optional The address of the company. Example: '123 Smarter Launch Way'

address2   string  optional  

optional The address of the company. Example: 'Suite 101'

city   string  optional  

optional The company city name. Example: Queen Creek

country_state_uuid   string  optional  

optional The company state uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

country_uuid   string  optional  

optional The company country uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

postal_code   string  optional  

optional The postal code of the company. Example: 85410

latitude   string  optional  

optional The latitude of the company. Example: 23.0396

longitude   string  optional  

optional The longitude of the company. Example: 72.566

enable_overrides   boolean  optional  

optional. Example: true

license_number   string  optional  

optional. Example: lc-123456

Delete

requires authentication

This endpoint enables user to delete a company location

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/8c10022e-a761-384f-bccf-99f389f946e2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/8c10022e-a761-384f-bccf-99f389f946e2';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/8c10022e-a761-384f-bccf-99f389f946e2"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/locations/{companyLocation_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyLocation_uuid   string   

Example: 8c10022e-a761-384f-bccf-99f389f946e2

uuid   string   

The uuid of the company location. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Integration Data

requires authentication

Get data from a 3rd party API

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/8a155b1c-d7e4-3321-a691-6744c6015984/integration-data" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/8a155b1c-d7e4-3321-a691-6744c6015984/integration-data';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/locations/8a155b1c-d7e4-3321-a691-6744c6015984/integration-data"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/locations/{companyLocation_uuid}/integration-data

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyLocation_uuid   string   

Example: 8a155b1c-d7e4-3321-a691-6744c6015984

uuid   string   

The uuid of the company location. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

integration_type_uuid   string   

The uuid of the integration type. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

force_look_up   string  optional  

Example: true

User Authentication

API for user authentication

Company Registration.

This endpoint lets company owner/manager to register.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/register" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"company_name\": \"Smarter Launch\",
    \"first_name\": \"John\",
    \"last_name\": \"Smith\",
    \"email\": \"hello@smarterlaunch.com\",
    \"password\": \"$m@4T34L@un(}{\",
    \"confirm_password\": \"$m@4T34L@un(}{\",
    \"referral_source\": \"google ad\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/register';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'company_name' => 'Smarter Launch',
            'first_name' => 'John',
            'last_name' => 'Smith',
            'email' => 'hello@smarterlaunch.com',
            'password' => '$m@4T34L@un(}{',
            'confirm_password' => '$m@4T34L@un(}{',
            'referral_source' => 'google ad',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/register"
);

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

let body = {
    "company_name": "Smarter Launch",
    "first_name": "John",
    "last_name": "Smith",
    "email": "hello@smarterlaunch.com",
    "password": "$m@4T34L@un(}{",
    "confirm_password": "$m@4T34L@un(}{",
    "referral_source": "google ad"
};

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

Request      

POST api/v1/auth/register

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

company_name   string   

The company name of the user. Example: Smarter Launch

first_name   string   

The first name of the user. Example: John

last_name   string   

The last name of the user. Example: Smith

email   string   

The email of the user. Example: hello@smarterlaunch.com

password   string   

The password of the user. Example: $m@4T34L@un(}{

confirm_password   string   

The same password for confirmation. Example: $m@4T34L@un(}{

referral_source   string  optional  

optional The referral source. Example: google ad

Company registration using social account.

This endpoint lets company to register using social account.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/register/social" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"social_type\": 1,
    \"code\": \"111806022046983237516\",
    \"referral_source\": \"google ad\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/register/social';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'social_type' => 1,
            'code' => '111806022046983237516',
            'referral_source' => 'google ad',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/register/social"
);

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

let body = {
    "social_type": 1,
    "code": "111806022046983237516",
    "referral_source": "google ad"
};

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

Request      

POST api/v1/auth/register/social

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

social_type   integer   

The login type of the user (Google = 1). Example: 1

code   string   

auth code of the user. Example: 111806022046983237516

referral_source   string  optional  

optional The referral source. Example: google ad

User registration based on company invite.

This endpoint lets you user to register himself who are invited by company.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/register/company-user" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"first_name\": \"John\",
    \"last_name\": \"Smith\",
    \"email\": \"hello@smarterlaunch.com\",
    \"password\": \"$m@4T34L@un(}{\",
    \"confirm_password\": \"$m@4T34L@un(}{\",
    \"token\": \"7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/register/company-user';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'first_name' => 'John',
            'last_name' => 'Smith',
            'email' => 'hello@smarterlaunch.com',
            'password' => '$m@4T34L@un(}{',
            'confirm_password' => '$m@4T34L@un(}{',
            'token' => '7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/register/company-user"
);

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

let body = {
    "first_name": "John",
    "last_name": "Smith",
    "email": "hello@smarterlaunch.com",
    "password": "$m@4T34L@un(}{",
    "confirm_password": "$m@4T34L@un(}{",
    "token": "7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE"
};

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

Request      

POST api/v1/auth/register/company-user

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

first_name   string   

The first name of the user. Example: John

last_name   string   

The last name of the user. Example: Smith

email   string   

The email of the user. Example: hello@smarterlaunch.com

password   string   

The password of the user. Example: $m@4T34L@un(}{

confirm_password   string   

The same password for confirmation. Example: $m@4T34L@un(}{

token   string   

To restrict unauthorized registration. Example: 7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE

User registration using social account based on company invite.

This endpoint lets user to register using social account.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/register/social/company-user" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email\": \"hello@smarterlaunch.com\",
    \"social_type\": 1,
    \"social_id\": \"111806022046983237516\",
    \"social_token_id\": \"eyRhbGciOiJSUzI1NiIsImtpZCI6Ijg1ODI4YzU5Jjg0YTY5YjU0YjI3NDgzZTQ4N2MzYmQ0NmNkMmEyYjMiLCJ0eXAiOiJKV1QifB\",
    \"token\": \"7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/register/social/company-user';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'email' => 'hello@smarterlaunch.com',
            'social_type' => 1,
            'social_id' => '111806022046983237516',
            'social_token_id' => 'eyRhbGciOiJSUzI1NiIsImtpZCI6Ijg1ODI4YzU5Jjg0YTY5YjU0YjI3NDgzZTQ4N2MzYmQ0NmNkMmEyYjMiLCJ0eXAiOiJKV1QifB',
            'token' => '7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/register/social/company-user"
);

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

let body = {
    "email": "hello@smarterlaunch.com",
    "social_type": 1,
    "social_id": "111806022046983237516",
    "social_token_id": "eyRhbGciOiJSUzI1NiIsImtpZCI6Ijg1ODI4YzU5Jjg0YTY5YjU0YjI3NDgzZTQ4N2MzYmQ0NmNkMmEyYjMiLCJ0eXAiOiJKV1QifB",
    "token": "7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE"
};

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

Request      

POST api/v1/auth/register/social/company-user

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

email   string   

The email of the user. Example: hello@smarterlaunch.com

social_type   integer   

The login type of the user (Google = 1). Example: 1

social_id   string   

The social id of the user provided by the 3rd party provider. Example: 111806022046983237516

social_token_id   string   

The social id of the user. Example: eyRhbGciOiJSUzI1NiIsImtpZCI6Ijg1ODI4YzU5Jjg0YTY5YjU0YjI3NDgzZTQ4N2MzYmQ0NmNkMmEyYjMiLCJ0eXAiOiJKV1QifB

token   string   

To restrict unauthorized registration. Example: 7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE

Login.

This endpoint allows common login into the system.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/login" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email\": \"hello@smarterlaunch.com\",
    \"password\": \"xxxxxx\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/login';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'email' => 'hello@smarterlaunch.com',
            'password' => 'xxxxxx',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/login"
);

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

let body = {
    "email": "hello@smarterlaunch.com",
    "password": "xxxxxx"
};

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

Request      

POST api/v1/auth/login

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

email   string   

The email-id of the user. Example: hello@smarterlaunch.com

password   string   

The password of the user. Example: xxxxxx

Social Login.

This endpoint lets you login into the system using a 3rd party provider.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/login/social" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"social_type\": 1,
    \"code\": \"111806022046983237516\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/login/social';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'social_type' => 1,
            'code' => '111806022046983237516',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/login/social"
);

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

let body = {
    "social_type": 1,
    "code": "111806022046983237516"
};

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

Request      

POST api/v1/auth/login/social

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

social_type   integer   

The login type of the user (Google = 1). Example: 1

code   string   

auth code of the user. Example: 111806022046983237516

Forgot password.

This endpoint lets user to get token to change password.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/forgot-password" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email\": \"hello@smarterlaunch.com\",
    \"token\": \"delectus\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/forgot-password';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'email' => 'hello@smarterlaunch.com',
            'token' => 'delectus',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/forgot-password"
);

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

let body = {
    "email": "hello@smarterlaunch.com",
    "token": "delectus"
};

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

Request      

POST api/v1/auth/forgot-password

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

email   string   

The email of the user. Example: hello@smarterlaunch.com

token   string  optional  

This field is required when email is not present. Example: delectus

Validate Bearer token.

This endpoint lets user to validate token, on success returns token object.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/token-validate" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"bearer_token\": \"eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9...\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/token-validate';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'bearer_token' => 'eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9...',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/token-validate"
);

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

let body = {
    "bearer_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9..."
};

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

Request      

POST api/v1/auth/token-validate

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

bearer_token   string  optional  

required. Example: eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9...

Get Token Expiration This endpoint allows client to retrieve their user token expiration date.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/auth/token-expiration" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email\": \"hello@smarterlaunch.com\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/token-expiration';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'email' => 'hello@smarterlaunch.com',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/token-expiration"
);

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

let body = {
    "email": "hello@smarterlaunch.com"
};

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

Request      

GET api/v1/auth/token-expiration

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

email   string   

The email of the user. Example: hello@smarterlaunch.com

Verify email.

This endpoint lets the user verify their email and login with token and password.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/verify-email" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email\": \"hello@smarterlaunch.com\",
    \"password\": \"$m@4T34L@un(}{\",
    \"token\": \"123456\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/verify-email';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'email' => 'hello@smarterlaunch.com',
            'password' => '$m@4T34L@un(}{',
            'token' => '123456',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/verify-email"
);

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

let body = {
    "email": "hello@smarterlaunch.com",
    "password": "$m@4T34L@un(}{",
    "token": "123456"
};

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

Request      

POST api/v1/auth/verify-email

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

email   string   

The email of the user. Example: hello@smarterlaunch.com

password   string   

The password of the user. Example: $m@4T34L@un(}{

token   string   

To restrict unauthorized registration. Example: 123456

Resend the email verification notification.

requires authentication

This endpoint lets user to resend email verification notification.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/verify-email-resend" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/verify-email-resend';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/verify-email-resend"
);

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

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

Request      

POST api/v1/auth/verify-email-resend

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Reset password.

requires authentication

This endpoint lets the user reset their password.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/reset-password" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"password\": \"$m@4T34L@un(}{\",
    \"confirm_password\": \"$m@4T34L@un(}{\",
    \"token\": \"7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE\",
    \"email\": \"hello@smarterlaunch.com\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/reset-password';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'password' => '$m@4T34L@un(}{',
            'confirm_password' => '$m@4T34L@un(}{',
            'token' => '7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE',
            'email' => 'hello@smarterlaunch.com',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/reset-password"
);

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

let body = {
    "password": "$m@4T34L@un(}{",
    "confirm_password": "$m@4T34L@un(}{",
    "token": "7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE",
    "email": "hello@smarterlaunch.com"
};

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

Request      

POST api/v1/auth/reset-password

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

password   string   

The password of the user. Example: $m@4T34L@un(}{

confirm_password   string   

The same password for confirmation. Example: $m@4T34L@un(}{

token   string   

To restrict unauthorized registration. Example: 7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE

email   string   

The email of the user. Example: hello@smarterlaunch.com

Check token validity.

requires authentication

This endpoint verifies the validity of a reset password token.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/check-token-validity" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"token\": \"7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/check-token-validity';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'token' => '7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/check-token-validity"
);

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

let body = {
    "token": "7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE"
};

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

Request      

POST api/v1/auth/check-token-validity

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

token   string   

The token to be verified. Example: 7hKxKlz5sKHlqXFkkCfsKpj9iVPoaSlM18Uv5JuehYXQfTme33XtxGmNQ1yE

Get invited user by token

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/auth/user-invite" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"token\": \"BMj4tHdI9jeRidv8O6emwqwepk34sl2tYrm1gakhDhqgOxdi7JO4BEkJG4yh\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/user-invite';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'token' => 'BMj4tHdI9jeRidv8O6emwqwepk34sl2tYrm1gakhDhqgOxdi7JO4BEkJG4yh',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/user-invite"
);

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

let body = {
    "token": "BMj4tHdI9jeRidv8O6emwqwepk34sl2tYrm1gakhDhqgOxdi7JO4BEkJG4yh"
};

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

Request      

GET api/v1/auth/user-invite

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

token   string   

The token provided for the invited user. Example: BMj4tHdI9jeRidv8O6emwqwepk34sl2tYrm1gakhDhqgOxdi7JO4BEkJG4yh

Logout.

requires authentication

let's user to logout.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/logout" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/logout';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/logout"
);

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

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

Request      

POST api/v1/auth/logout

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

User Device Management.

requires authentication

This endpoint lets user to add device information.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/device-info/store" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"pushtoken\": \"xxxxx\",
    \"device_name\": \"iPhone 12\",
    \"device_id\": \"skdlfsk-sfs-dsfsdf-sdfs\",
    \"app_version\": \"v1\",
    \"os_version\": \"iOS 14.1\",
    \"time_zone\": \"NZ\",
    \"platform\": \"Apple\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/device-info/store';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'pushtoken' => 'xxxxx',
            'device_name' => 'iPhone 12',
            'device_id' => 'skdlfsk-sfs-dsfsdf-sdfs',
            'app_version' => 'v1',
            'os_version' => 'iOS 14.1',
            'time_zone' => 'NZ',
            'platform' => 'Apple',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/device-info/store"
);

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

let body = {
    "pushtoken": "xxxxx",
    "device_name": "iPhone 12",
    "device_id": "skdlfsk-sfs-dsfsdf-sdfs",
    "app_version": "v1",
    "os_version": "iOS 14.1",
    "time_zone": "NZ",
    "platform": "Apple"
};

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

Request      

POST api/v1/device-info/store

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

pushtoken   string   

The push-token. Example: xxxxx

device_name   string   

The device name of the device. Example: iPhone 12

device_id   string   

The device id of the device. Example: skdlfsk-sfs-dsfsdf-sdfs

app_version   string   

The app version of the device. Example: v1

os_version   string   

The os version of the device. Example: iOS 14.1

time_zone   string   

The time zone of the user. Example: NZ

platform   string   

The platform of the device. Example: Apple

Company Integration

API for Company Integration

Generic handler for company integration actions

requires authentication

If the method exists within the CompanyIntegrationController, it will be called, otherwise it will be passed to the integration type if the method exists there.

If the endpoint is a no-auth endpoint, we will allow it to be executed without going through the auth middleware. This is useful for endpoints that are called by customers that aren't logged in. The endpoint must be explicitly defined to be a no-auth endpoint in the integration type.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/3886aef1-4a0b-3039-b39a-232014e9abba/in" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/3886aef1-4a0b-3039-b39a-232014e9abba/in';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/3886aef1-4a0b-3039-b39a-232014e9abba/in"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/integrations/{companyIntegration_uuid}/{action}

POST api/v1/companies/{company_uuid}/integrations/{companyIntegration_uuid}/{action}

PUT api/v1/companies/{company_uuid}/integrations/{companyIntegration_uuid}/{action}

PATCH api/v1/companies/{company_uuid}/integrations/{companyIntegration_uuid}/{action}

DELETE api/v1/companies/{company_uuid}/integrations/{companyIntegration_uuid}/{action}

OPTIONS api/v1/companies/{company_uuid}/integrations/{companyIntegration_uuid}/{action}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyIntegration_uuid   string   

Example: 3886aef1-4a0b-3039-b39a-232014e9abba

action   string   

Example: in

Generic handler for integration type actions

requires authentication

it will be passed to the integration type if the method exists there.

If the endpoint is a no-auth endpoint, we will allow it to be executed without going through the auth middleware. This is useful for endpoints that are called by customers that aren't logged in. The endpoint must be explicitly defined to be a no-auth endpoint in the integration type.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/integration-types/1/veniam" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/integration-types/1/veniam';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/integration-types/1/veniam"
);

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

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

Request      

GET api/v1/integration-types/{integrationType_type_code}/{action}

POST api/v1/integration-types/{integrationType_type_code}/{action}

PUT api/v1/integration-types/{integrationType_type_code}/{action}

PATCH api/v1/integration-types/{integrationType_type_code}/{action}

DELETE api/v1/integration-types/{integrationType_type_code}/{action}

OPTIONS api/v1/integration-types/{integrationType_type_code}/{action}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

integrationType_type_code   integer   

Example: 1

action   string   

Example: veniam

List

requires authentication

Shows the list of integrations for a company

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/integrations

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Show

requires authentication

Shows a single item of integrations for a company

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/b95e7a6c-02db-3fa0-8489-da291f3161a8" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/b95e7a6c-02db-3fa0-8489-da291f3161a8';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/b95e7a6c-02db-3fa0-8489-da291f3161a8"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/integrations/{companyIntegration_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyIntegration_uuid   string   

Example: b95e7a6c-02db-3fa0-8489-da291f3161a8

company_integration_uuid   string  optional  

uuid required The UUID of the company integration that is to be updated. Example: 3245d634-24fd-11ec-accd-e397aec85c7f

Store

requires authentication

Create a company integration with empty credential values

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"integration_type_uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'integration_type_uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations"
);

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

let body = {
    "integration_type_uuid": "3245d630-24fd-11ec-accd-e397aec85c7f"
};

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

Request      

POST api/v1/companies/{company_uuid}/integrations

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

integration_type_uuid   uuid   

The integration type UUID. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Update

requires authentication

This endpoint updates the company integration and triggers the sync process (if applicable) if the data is verified and the status is set to active.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/28b0993b-1f72-33aa-be36-92a804149518" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"credentials\": [
        \"et\"
    ],
    \"status_uuid\": \"fd22e1df-3531-34d9-8089-a055fb938977\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/28b0993b-1f72-33aa-be36-92a804149518';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'credentials' => [
                'et',
            ],
            'status_uuid' => 'fd22e1df-3531-34d9-8089-a055fb938977',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/28b0993b-1f72-33aa-be36-92a804149518"
);

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

let body = {
    "credentials": [
        "et"
    ],
    "status_uuid": "fd22e1df-3531-34d9-8089-a055fb938977"
};

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

Request      

PUT api/v1/companies/{company_uuid}/integrations/{companyIntegration_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyIntegration_uuid   string   

Example: 28b0993b-1f72-33aa-be36-92a804149518

company_integration_uuid   string  optional  

uuid required The UUID of the company integration that is to be updated. Example: 3245d634-24fd-11ec-accd-e397aec85c7f

Body Parameters

credentials   string[]   

The credentials for the company integration

status_uuid   uuid   

The status UUID for company integration Example: fd22e1df-3531-34d9-8089-a055fb938977

Patch

requires authentication

This endpoint patch the company integration and triggers the sync process if the data is verified and the status is set to active.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/3d9f4efd-264d-32d5-99e1-b2617bc3f480" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"credentials\": [
        \"aperiam\"
    ],
    \"status_uuid\": \"7f957619-af63-315d-ab7b-2d5b12c92cdf\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/3d9f4efd-264d-32d5-99e1-b2617bc3f480';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'credentials' => [
                'aperiam',
            ],
            'status_uuid' => '7f957619-af63-315d-ab7b-2d5b12c92cdf',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/3d9f4efd-264d-32d5-99e1-b2617bc3f480"
);

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

let body = {
    "credentials": [
        "aperiam"
    ],
    "status_uuid": "7f957619-af63-315d-ab7b-2d5b12c92cdf"
};

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

Request      

PATCH api/v1/companies/{company_uuid}/integrations/{companyIntegration_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyIntegration_uuid   string   

Example: 3d9f4efd-264d-32d5-99e1-b2617bc3f480

company_integration_uuid   string  optional  

uuid required The UUID of the company integration that is to be updated. Example: 3245d634-24fd-11ec-accd-e397aec85c7f

Body Parameters

credentials   string[]   

The credentials for the company integration

status_uuid   uuid   

The status uuid for company integration Example: 7f957619-af63-315d-ab7b-2d5b12c92cdf

Delete

requires authentication

This endpoint allows user to delete a Company Integration.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/2cbd4c87-78f0-3058-aab1-61984a83d7ce" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/2cbd4c87-78f0-3058-aab1-61984a83d7ce';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/integrations/2cbd4c87-78f0-3058-aab1-61984a83d7ce"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/integrations/{companyIntegration_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyIntegration_uuid   string   

Example: 2cbd4c87-78f0-3058-aab1-61984a83d7ce

company_integration_uuid   string  optional  

uuid required The UUID of the company integration that is to be updated. Example: 3245d634-24fd-11ec-accd-e397aec85c7f

List Integration Types

requires authentication

Shows the list of integration types available for a company.
Note: Only administrators have access to certain integration types.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/integrations" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/integrations';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/integrations"
);

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

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

Request      

GET api/v1/integrations

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Company Symbol

API for company symbol details

List

requires authentication

Shows the list of company symbols with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/symbols

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 6

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 18

sort_by   string  optional  

The column name. Example : name Example: quia

sort_order   string  optional  

The order in which you want your records. Example : asc Example: distinctio

search   string  optional  

The general search, it will find matching string. Example : home Example: eius

with_trashed   string  optional  

boolean To display soft deleted data as well. Example : true Example: veniam

category_uuids   string  optional  

string[] To filter symbols by category. Example : [3245d630-24fd-11ec-accd-e397aec85c7f, 3245d630-24fd-11ec-accd-e397aec85c7f] Example: consectetur

Show

requires authentication

Show a single company symbol.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/0f4ed437-5f69-3aa2-b488-65f6b2d65a7b" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/0f4ed437-5f69-3aa2-b488-65f6b2d65a7b';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/0f4ed437-5f69-3aa2-b488-65f6b2d65a7b"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/symbols/{companySymbol_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companySymbol_uuid   string   

Example: 0f4ed437-5f69-3aa2-b488-65f6b2d65a7b

Store

requires authentication

Store a newly created company symbol.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "name=vel"\
    --form "source=consequuntur"\
    --form "description=Rerum incidunt distinctio enim et."\
    --form "icon_url=http://smarterlaunch.local/image1.jpg"\
    --form "company_product_uuids[]=deleniti"\
    --form "icon_file=@/tmp/phpoiZddT" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'name',
                'contents' => 'vel'
            ],
            [
                'name' => 'source',
                'contents' => 'consequuntur'
            ],
            [
                'name' => 'description',
                'contents' => 'Rerum incidunt distinctio enim et.'
            ],
            [
                'name' => 'icon_url',
                'contents' => 'http://smarterlaunch.local/image1.jpg'
            ],
            [
                'name' => 'company_product_uuids[]',
                'contents' => 'deleniti'
            ],
            [
                'name' => 'icon_file',
                'contents' => fopen('/tmp/phpoiZddT', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('name', 'vel');
body.append('source', 'consequuntur');
body.append('description', 'Rerum incidunt distinctio enim et.');
body.append('icon_url', 'http://smarterlaunch.local/image1.jpg');
body.append('company_product_uuids[]', 'deleniti');
body.append('icon_file', document.querySelector('input[name="icon_file"]').files[0]);

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

Request      

POST api/v1/companies/{company_uuid}/symbols

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the symbol. Example : Dig Example: vel

source   string   

The source of the symbol. Example : text Example: consequuntur

description   string  optional  

optional The description of the symbol. Example : text Example: Rerum incidunt distinctio enim et.

icon_url   string  optional  

optional The image url of the symbol. Example: http://smarterlaunch.local/image1.jpg

icon_file   file  optional  

optional The file of the symbol image. Example: /tmp/phpoiZddT

company_product_uuids   string[]  optional  

of string optional The products of the symbol.

Update

requires authentication

Update a company symbol.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/578e3ba1-9418-33fb-9500-ce93bab378f5" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "name=libero"\
    --form "source=est"\
    --form "description=Illo aliquam tempora quisquam laudantium est sit."\
    --form "icon_url=http://smarterlaunch.local/image1.jpg"\
    --form "company_product_uuids[]=dignissimos"\
    --form "icon_file=@/tmp/phpz706ES" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/578e3ba1-9418-33fb-9500-ce93bab378f5';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'name',
                'contents' => 'libero'
            ],
            [
                'name' => 'source',
                'contents' => 'est'
            ],
            [
                'name' => 'description',
                'contents' => 'Illo aliquam tempora quisquam laudantium est sit.'
            ],
            [
                'name' => 'icon_url',
                'contents' => 'http://smarterlaunch.local/image1.jpg'
            ],
            [
                'name' => 'company_product_uuids[]',
                'contents' => 'dignissimos'
            ],
            [
                'name' => 'icon_file',
                'contents' => fopen('/tmp/phpz706ES', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/578e3ba1-9418-33fb-9500-ce93bab378f5"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('name', 'libero');
body.append('source', 'est');
body.append('description', 'Illo aliquam tempora quisquam laudantium est sit.');
body.append('icon_url', 'http://smarterlaunch.local/image1.jpg');
body.append('company_product_uuids[]', 'dignissimos');
body.append('icon_file', document.querySelector('input[name="icon_file"]').files[0]);

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

Request      

PUT api/v1/companies/{company_uuid}/symbols/{companySymbol_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companySymbol_uuid   string   

Example: 578e3ba1-9418-33fb-9500-ce93bab378f5

companySymbolUuid   string   

The uuid of the symbol. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

name   string   

The name of the symbol. Example : Dig Example: libero

source   string   

The source of the symbol. Example : text Example: est

description   string  optional  

optional The description of the symbol. Example : text Example: Illo aliquam tempora quisquam laudantium est sit.

icon_url   string  optional  

optional The image url of the symbol. Example: http://smarterlaunch.local/image1.jpg

icon_file   file  optional  

optional The file of the symbol image. Example: /tmp/phpz706ES

company_product_uuids   string[]  optional  

of string optional The products of the symbol.

Update

requires authentication

Update a company symbol.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/bf1c9355-47c9-3014-92f6-5644e0974d2b" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "name=reiciendis"\
    --form "source=et"\
    --form "description=Itaque enim provident quasi aliquam velit enim."\
    --form "icon_url=http://smarterlaunch.local/image1.jpg"\
    --form "company_product_uuids[]=perspiciatis"\
    --form "icon_file=@/tmp/phpusXb6O" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/bf1c9355-47c9-3014-92f6-5644e0974d2b';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'name',
                'contents' => 'reiciendis'
            ],
            [
                'name' => 'source',
                'contents' => 'et'
            ],
            [
                'name' => 'description',
                'contents' => 'Itaque enim provident quasi aliquam velit enim.'
            ],
            [
                'name' => 'icon_url',
                'contents' => 'http://smarterlaunch.local/image1.jpg'
            ],
            [
                'name' => 'company_product_uuids[]',
                'contents' => 'perspiciatis'
            ],
            [
                'name' => 'icon_file',
                'contents' => fopen('/tmp/phpusXb6O', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/bf1c9355-47c9-3014-92f6-5644e0974d2b"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('name', 'reiciendis');
body.append('source', 'et');
body.append('description', 'Itaque enim provident quasi aliquam velit enim.');
body.append('icon_url', 'http://smarterlaunch.local/image1.jpg');
body.append('company_product_uuids[]', 'perspiciatis');
body.append('icon_file', document.querySelector('input[name="icon_file"]').files[0]);

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

Request      

POST api/v1/companies/{company_uuid}/symbols/{companySymbol_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companySymbol_uuid   string   

Example: bf1c9355-47c9-3014-92f6-5644e0974d2b

companySymbolUuid   string   

The uuid of the symbol. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

name   string   

The name of the symbol. Example : Dig Example: reiciendis

source   string   

The source of the symbol. Example : text Example: et

description   string  optional  

optional The description of the symbol. Example : text Example: Itaque enim provident quasi aliquam velit enim.

icon_url   string  optional  

optional The image url of the symbol. Example: http://smarterlaunch.local/image1.jpg

icon_file   file  optional  

optional The file of the symbol image. Example: /tmp/phpusXb6O

company_product_uuids   string[]  optional  

of string optional The products of the symbol.

Patch

requires authentication

Patch a company symbol.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/37c71b0e-6a28-3e43-a69e-8e2bef61cd54" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "name=quo"\
    --form "source=fuga"\
    --form "description=Iusto commodi recusandae quidem ut autem."\
    --form "icon_url=http://smarterlaunch.local/image1.jpg"\
    --form "icon_file=@/tmp/php06Y1MS" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/37c71b0e-6a28-3e43-a69e-8e2bef61cd54';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'name',
                'contents' => 'quo'
            ],
            [
                'name' => 'source',
                'contents' => 'fuga'
            ],
            [
                'name' => 'description',
                'contents' => 'Iusto commodi recusandae quidem ut autem.'
            ],
            [
                'name' => 'icon_url',
                'contents' => 'http://smarterlaunch.local/image1.jpg'
            ],
            [
                'name' => 'icon_file',
                'contents' => fopen('/tmp/php06Y1MS', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/37c71b0e-6a28-3e43-a69e-8e2bef61cd54"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('name', 'quo');
body.append('source', 'fuga');
body.append('description', 'Iusto commodi recusandae quidem ut autem.');
body.append('icon_url', 'http://smarterlaunch.local/image1.jpg');
body.append('icon_file', document.querySelector('input[name="icon_file"]').files[0]);

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

Request      

PATCH api/v1/companies/{company_uuid}/symbols/{companySymbol_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companySymbol_uuid   string   

Example: 37c71b0e-6a28-3e43-a69e-8e2bef61cd54

companySymbolUuid   string   

The uuid of the symbol. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

name   string   

The name of the symbol. Example : Dig Example: quo

source   string   

The source of the symbol. Example : text Example: fuga

description   string  optional  

optional The description of the symbol. Example : text Example: Iusto commodi recusandae quidem ut autem.

icon_url   string  optional  

optional The image url of the symbol. Example: http://smarterlaunch.local/image1.jpg

icon_file   file  optional  

optional The file of the symbol image. Example: /tmp/php06Y1MS

Delete

requires authentication

Delete a company symbol.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/869d3142-48de-370e-8a37-a72ff1e5ac0b" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/869d3142-48de-370e-8a37-a72ff1e5ac0b';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/symbols/869d3142-48de-370e-8a37-a72ff1e5ac0b"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/symbols/{companySymbol_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companySymbol_uuid   string   

Example: 869d3142-48de-370e-8a37-a72ff1e5ac0b

Support Request

API for Support Request

Store

requires authentication

Send support request from users

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/support-request" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"support_type\": \"\'General Inquiry\'\",
    \"description\": \"\'I cannot access documents. Please help.\'\",
    \"screenshots_url\": [
        \"https:\\/\\/example.net\\/image1.jpg\",
        \"https:\\/\\/example.net\\/image1.png\"
    ],
    \"no_attachments\": false
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/support-request';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'support_type' => '\'General Inquiry\'',
            'description' => '\'I cannot access documents. Please help.\'',
            'screenshots_url' => [
                'https://example.net/image1.jpg',
                'https://example.net/image1.png',
            ],
            'no_attachments' => false,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/support-request"
);

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

let body = {
    "support_type": "'General Inquiry'",
    "description": "'I cannot access documents. Please help.'",
    "screenshots_url": [
        "https:\/\/example.net\/image1.jpg",
        "https:\/\/example.net\/image1.png"
    ],
    "no_attachments": false
};

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

Request      

POST api/v1/support-request

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

support_type   string   

The support type. Example: 'General Inquiry'

description   string   

The support request details. Example: 'I cannot access documents. Please help.'

recordings   object  optional  
client_detail   object  optional  
screenshots_url   string[]   

The screenshots URL string.

error_detail   object  optional  
no_attachments   boolean   

Check if request has attachments. Example: false

Upload

requires authentication

Upload photos for Cover Letter or Photo Layout pages

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/support-request-upload/93cf5a04-7f92-3c96-8d2b-86d80bbede33" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "document_template_page_title=Cover Letter"\
    --form "title=Cover Letter Featured Image"\
    --form "decription=Lorem ipsum dolor"\
    --form "append=1"\
    --form "screenshot_file=@/tmp/php4KHPkR" \
    --form "photo_file=@/tmp/phpUNbe4R" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/support-request-upload/93cf5a04-7f92-3c96-8d2b-86d80bbede33';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'document_template_page_title',
                'contents' => 'Cover Letter'
            ],
            [
                'name' => 'title',
                'contents' => 'Cover Letter Featured Image'
            ],
            [
                'name' => 'decription',
                'contents' => 'Lorem ipsum dolor'
            ],
            [
                'name' => 'append',
                'contents' => '1'
            ],
            [
                'name' => 'screenshot_file',
                'contents' => fopen('/tmp/php4KHPkR', 'r')
            ],
            [
                'name' => 'photo_file',
                'contents' => fopen('/tmp/phpUNbe4R', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/support-request-upload/93cf5a04-7f92-3c96-8d2b-86d80bbede33"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('document_template_page_title', 'Cover Letter');
body.append('title', 'Cover Letter Featured Image');
body.append('decription', 'Lorem ipsum dolor');
body.append('append', '1');
body.append('screenshot_file', document.querySelector('input[name="screenshot_file"]').files[0]);
body.append('photo_file', document.querySelector('input[name="photo_file"]').files[0]);

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

Request      

POST api/v1/support-request-upload/{supportRequest_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

supportRequest_uuid   string   

Example: 93cf5a04-7f92-3c96-8d2b-86d80bbede33

Body Parameters

screenshot_file   file   

Must be a file. Must be an image. Example: /tmp/php4KHPkR

document_template_page_title   string   

The template page title. Example: Cover Letter

photo_file   file   

The photo of template page. Example: /tmp/phpUNbe4R

title   string  optional  

optional The title of the photo. Example: Cover Letter Featured Image

decription   string  optional  

optional The description of the photo. Example: Lorem ipsum dolor

append   boolean  optional  

optional Determine whether to append uploaded photo to existing photos of template page. Example: true

Pest Treated

List

requires authentication

Shows the list of pest treated with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/pests-treated

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 2

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 3

sort_by   string  optional  

The column name. Example : name Example: est

sort_order   string  optional  

The order in which you want your records. Example : asc Example: fugit

search   string  optional  

The general search, it will find matching string. Example : home Example: magnam

Show

requires authentication

Show a single pest treated.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/fb0723e8-2ec8-3ca7-b8fb-8cd9dabdf5bb" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/fb0723e8-2ec8-3ca7-b8fb-8cd9dabdf5bb';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/fb0723e8-2ec8-3ca7-b8fb-8cd9dabdf5bb"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/pests-treated/{pestTreated_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

pestTreated_uuid   string   

Example: fb0723e8-2ec8-3ca7-b8fb-8cd9dabdf5bb

Store

requires authentication

Store a newly created pest treated.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "name=nihil"\
    --form "pest_treated_attributes[attr]=value"\
    --form "icon_image_url=http://smarterlaunch.local/image1.jpg"\
    --form "pest_treated="\
    --form "photo_file=@/tmp/phpsfMrMS" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'name',
                'contents' => 'nihil'
            ],
            [
                'name' => 'pest_treated_attributes[attr]',
                'contents' => 'value'
            ],
            [
                'name' => 'icon_image_url',
                'contents' => 'http://smarterlaunch.local/image1.jpg'
            ],
            [
                'name' => 'pest_treated',
                'contents' => ''
            ],
            [
                'name' => 'photo_file',
                'contents' => fopen('/tmp/phpsfMrMS', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('name', 'nihil');
body.append('pest_treated_attributes[attr]', 'value');
body.append('icon_image_url', 'http://smarterlaunch.local/image1.jpg');
body.append('pest_treated', '');
body.append('photo_file', document.querySelector('input[name="photo_file"]').files[0]);

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

Request      

POST api/v1/companies/{company_uuid}/pests-treated

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the pest treated. Example : Pest Treated 1 Example: nihil

pest_treated_attributes   object   

The attributes of the pest treated.

icon_image_url   string  optional  

optional The image url of the pest treated. Example: http://smarterlaunch.local/image1.jpg

photo_file   file  optional  

optional The file of the pest treated image. Example: /tmp/phpsfMrMS

pest_treated   object[]  optional  

optional An array of the above parameters.

Update

requires authentication

Update a pest treated.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/25fae297-63ce-3bcf-a8c2-a0f2aeca14fc" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "name=perferendis"\
    --form "pest_treated_attributes[attr]=value"\
    --form "icon_image_url=http://smarterlaunch.local/image1.jpg"\
    --form "photo_file=@/tmp/phpzsbMIQ" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/25fae297-63ce-3bcf-a8c2-a0f2aeca14fc';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'name',
                'contents' => 'perferendis'
            ],
            [
                'name' => 'pest_treated_attributes[attr]',
                'contents' => 'value'
            ],
            [
                'name' => 'icon_image_url',
                'contents' => 'http://smarterlaunch.local/image1.jpg'
            ],
            [
                'name' => 'photo_file',
                'contents' => fopen('/tmp/phpzsbMIQ', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/25fae297-63ce-3bcf-a8c2-a0f2aeca14fc"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('name', 'perferendis');
body.append('pest_treated_attributes[attr]', 'value');
body.append('icon_image_url', 'http://smarterlaunch.local/image1.jpg');
body.append('photo_file', document.querySelector('input[name="photo_file"]').files[0]);

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

Request      

PUT api/v1/companies/{company_uuid}/pests-treated/{pestTreated_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

pestTreated_uuid   string   

Example: 25fae297-63ce-3bcf-a8c2-a0f2aeca14fc

Body Parameters

name   string   

The name of the pest treated. Example : Pest Treated 1 Example: perferendis

pest_treated_attributes   object   

The attributes of the pest treated.

icon_image_url   string  optional  

optional The image url of the pest treated. Example: http://smarterlaunch.local/image1.jpg

photo_file   file  optional  

optional The file of the pest treated image. Example: /tmp/phpzsbMIQ

Update

requires authentication

Update a pest treated.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/8b011064-3a3a-33c3-a165-e4f73c318e11" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "name=eos"\
    --form "pest_treated_attributes[attr]=value"\
    --form "icon_image_url=http://smarterlaunch.local/image1.jpg"\
    --form "photo_file=@/tmp/php12j5WQ" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/8b011064-3a3a-33c3-a165-e4f73c318e11';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'name',
                'contents' => 'eos'
            ],
            [
                'name' => 'pest_treated_attributes[attr]',
                'contents' => 'value'
            ],
            [
                'name' => 'icon_image_url',
                'contents' => 'http://smarterlaunch.local/image1.jpg'
            ],
            [
                'name' => 'photo_file',
                'contents' => fopen('/tmp/php12j5WQ', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/8b011064-3a3a-33c3-a165-e4f73c318e11"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('name', 'eos');
body.append('pest_treated_attributes[attr]', 'value');
body.append('icon_image_url', 'http://smarterlaunch.local/image1.jpg');
body.append('photo_file', document.querySelector('input[name="photo_file"]').files[0]);

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

Request      

POST api/v1/companies/{company_uuid}/pests-treated/{pestTreated_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

pestTreated_uuid   string   

Example: 8b011064-3a3a-33c3-a165-e4f73c318e11

Body Parameters

name   string   

The name of the pest treated. Example : Pest Treated 1 Example: eos

pest_treated_attributes   object   

The attributes of the pest treated.

icon_image_url   string  optional  

optional The image url of the pest treated. Example: http://smarterlaunch.local/image1.jpg

photo_file   file  optional  

optional The file of the pest treated image. Example: /tmp/php12j5WQ

Patch

requires authentication

Patch a company pest treated.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/9b3ca38b-9aa1-30ee-9c68-464261944120" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "name=sit"\
    --form "pest_treated_attributes[attr]=value"\
    --form "icon_image_url=http://smarterlaunch.local/image1.jpg"\
    --form "photo_file=@/tmp/php0ZzOsS" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/9b3ca38b-9aa1-30ee-9c68-464261944120';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'name',
                'contents' => 'sit'
            ],
            [
                'name' => 'pest_treated_attributes[attr]',
                'contents' => 'value'
            ],
            [
                'name' => 'icon_image_url',
                'contents' => 'http://smarterlaunch.local/image1.jpg'
            ],
            [
                'name' => 'photo_file',
                'contents' => fopen('/tmp/php0ZzOsS', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/9b3ca38b-9aa1-30ee-9c68-464261944120"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('name', 'sit');
body.append('pest_treated_attributes[attr]', 'value');
body.append('icon_image_url', 'http://smarterlaunch.local/image1.jpg');
body.append('photo_file', document.querySelector('input[name="photo_file"]').files[0]);

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

Request      

PATCH api/v1/companies/{company_uuid}/pests-treated/{pestTreated_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

pestTreated_uuid   string   

Example: 9b3ca38b-9aa1-30ee-9c68-464261944120

Body Parameters

name   string  optional  

optional The name of the pest treated. Example : Pest Treated 1 Example: sit

pest_treated_attributes   object  optional  

optional The attributes of the pest treated.

icon_image_url   string  optional  

optional The image url of the pest treated. Example: http://smarterlaunch.local/image1.jpg

photo_file   file  optional  

optional The file of the pest treated image. Example: /tmp/php0ZzOsS

Delete

requires authentication

Delete a pest treated.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/610628ca-7214-3cfb-b95f-1df5e38f928f" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/610628ca-7214-3cfb-b95f-1df5e38f928f';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/pests-treated/610628ca-7214-3cfb-b95f-1df5e38f928f"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/pests-treated/{pestTreated_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

pestTreated_uuid   string   

Example: 610628ca-7214-3cfb-b95f-1df5e38f928f

Media Source

API for Media Source

List

requires authentication

Shows the list of media source with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/media-sources" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-sources';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-sources"
);

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

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

Request      

GET api/v1/media-sources

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 1

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 13

sort_by   string  optional  

The column name. Example : name Example: dolore

sort_order   string  optional  

The order in which you want your records. Example : asc Example: incidunt

search   string  optional  

The general search, it will find matching string. Example : home Example: eaque

Body Parameters

types   object  optional  
Must be one of:
  • AUDIO
  • IMAGE
  • VIDEO
  • DOCUMENT
  • EMBED

Favorite Media Source List

requires authentication

Get the list of favorite Media Sources

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/media-sources/favorites" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"labore\",
    \"description\": \"Omnis et inventore velit iusto.\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-sources/favorites';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'labore',
            'description' => 'Omnis et inventore velit iusto.',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/favorites"
);

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

let body = {
    "name": "labore",
    "description": "Omnis et inventore velit iusto."
};

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

Request      

GET api/v1/media-sources/favorites

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

name   string   

The name of the media source. Example : "My media source" Example: labore

description   string  optional  

The description of the media source. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: Omnis et inventore velit iusto.

Show

requires authentication

Show a single media source

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/media-sources/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-sources/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1"
);

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

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

Request      

GET api/v1/media-sources/{mediaSource_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaSource_uuid   integer   

Example: 1

Store

requires authentication

Upload a media source

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/media-sources" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"sed\",
    \"description\": \"Enim ut qui quia numquam adipisci.\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-sources';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'sed',
            'description' => 'Enim ut qui quia numquam adipisci.',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-sources"
);

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

let body = {
    "name": "sed",
    "description": "Enim ut qui quia numquam adipisci."
};

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

Request      

POST api/v1/media-sources

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

name   string  optional  

The name of the file. Example : MyFile.txt Example: sed

description   string  optional  

The description of the file. Example : This is a sample description for uploaded file Example: Enim ut qui quia numquam adipisci.

Add to Favorite

requires authentication

Add media source to the user company's media source favorites

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1/favorites" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"autem\",
    \"description\": \"Beatae illum dignissimos sed voluptatem ullam.\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-sources/1/favorites';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'autem',
            'description' => 'Beatae illum dignissimos sed voluptatem ullam.',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1/favorites"
);

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

let body = {
    "name": "autem",
    "description": "Beatae illum dignissimos sed voluptatem ullam."
};

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

Request      

POST api/v1/media-sources/{mediaSource_uuid}/favorites

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaSource_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the media source. Example : "My media source" Example: autem

description   string  optional  

The description of the media source. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: Beatae illum dignissimos sed voluptatem ullam.

Import CSV

requires authentication

Accept CSV and populate media item data for a media source/manufacturer

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1/import-csv" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "file=@/tmp/phpUrDACQ" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-sources/1/import-csv';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'file',
                'contents' => fopen('/tmp/phpUrDACQ', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1/import-csv"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('file', document.querySelector('input[name="file"]').files[0]);

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

Request      

POST api/v1/media-sources/{mediaSource_uuid}/import-csv

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

mediaSource_uuid   integer   

Example: 1

Body Parameters

file   file   

The name of the media source. Example : "company.csv" Example: /tmp/phpUrDACQ

Update

requires authentication

Update a media source.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"commodi\",
    \"description\": \"Enim est nesciunt fugiat laboriosam.\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-sources/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'commodi',
            'description' => 'Enim est nesciunt fugiat laboriosam.',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1"
);

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

let body = {
    "name": "commodi",
    "description": "Enim est nesciunt fugiat laboriosam."
};

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

Request      

PUT api/v1/media-sources/{mediaSource_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaSource_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the media source. Example : "My media source" Example: commodi

description   string  optional  

The description of the media source. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: Enim est nesciunt fugiat laboriosam.

Patch

requires authentication

Patch a media source.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"eius\",
    \"description\": \"Magnam occaecati praesentium ut in voluptatem maxime doloribus consequuntur.\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-sources/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'eius',
            'description' => 'Magnam occaecati praesentium ut in voluptatem maxime doloribus consequuntur.',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1"
);

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

let body = {
    "name": "eius",
    "description": "Magnam occaecati praesentium ut in voluptatem maxime doloribus consequuntur."
};

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

Request      

PATCH api/v1/media-sources/{mediaSource_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaSource_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the media source. Example : "My media source" Example: eius

description   string  optional  

The description of the media source. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: Magnam occaecati praesentium ut in voluptatem maxime doloribus consequuntur.

Delete

requires authentication

Delete a media source.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-sources/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1"
);

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

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

Request      

DELETE api/v1/media-sources/{mediaSource_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaSource_uuid   integer   

Example: 1

Remove Favorite Media Source

requires authentication

Remove media source to the user company's media source favorites

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1/favorites" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"at\",
    \"description\": \"Cupiditate odio quia est doloremque modi totam iure mollitia.\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-sources/1/favorites';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'at',
            'description' => 'Cupiditate odio quia est doloremque modi totam iure mollitia.',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-sources/1/favorites"
);

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

let body = {
    "name": "at",
    "description": "Cupiditate odio quia est doloremque modi totam iure mollitia."
};

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

Request      

DELETE api/v1/media-sources/{mediaSource_uuid}/favorites

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaSource_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the media source. Example : "My media source" Example: at

description   string  optional  

The description of the media source. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: Cupiditate odio quia est doloremque modi totam iure mollitia.

Proposal Templates

List

requires authentication

Shows the list of ProposalTemplates with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/proposals/templates" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/templates';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/templates"
);

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

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

Request      

GET api/v1/proposals/templates

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 11

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 15

sort_by   string  optional  

The column name. Example : name Example: rerum

sort_order   string  optional  

The order in which you want your records. Example : asc Example: sit

search   string  optional  

The general search, it will find matching string. Example : home Example: et

string   string  optional  

The filter for proposal templates with company location in company_locations_uuid. Example: ["725d1dcd-54ad-3a8b-a28e-830c43d8ed6c", "b033658c-4532-3dd7-9be7-64433580eda6"]

Store

requires authentication

Store a newly created Proposal Template.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/templates" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"company_location_uuid\": \"1254238e-428d-3525-b269-6839a2242f00\",
    \"title\": \"quis\",
    \"description\": \"Alias sit voluptatum autem.\",
    \"settings\": {
        \"attr\": \"value\"
    },
    \"service_plan_uuids\": [
        \"815d3d9c-f371-3781-8456-7e6954b5b0f5\",
        \"815d3d9c-f371-3781-8456-7e6954b5b0f5\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/templates';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'company_location_uuid' => '1254238e-428d-3525-b269-6839a2242f00',
            'title' => 'quis',
            'description' => 'Alias sit voluptatum autem.',
            'settings' => [
                'attr' => 'value',
            ],
            'service_plan_uuids' => [
                '815d3d9c-f371-3781-8456-7e6954b5b0f5',
                '815d3d9c-f371-3781-8456-7e6954b5b0f5',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/templates"
);

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

let body = {
    "company_location_uuid": "1254238e-428d-3525-b269-6839a2242f00",
    "title": "quis",
    "description": "Alias sit voluptatum autem.",
    "settings": {
        "attr": "value"
    },
    "service_plan_uuids": [
        "815d3d9c-f371-3781-8456-7e6954b5b0f5",
        "815d3d9c-f371-3781-8456-7e6954b5b0f5"
    ]
};

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

Request      

POST api/v1/proposals/templates

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

company_location_uuid   string   

The uuid of company location for proposal template. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 1254238e-428d-3525-b269-6839a2242f00

title   string   

The name of the proposal template. Example : Proposal Template 1 Example: quis

description   string  optional  

The name of the proposal template. Example : This is a sample description Example: Alias sit voluptatum autem.

settings   object  optional  

The attributes of the proposal template.

service_plan_uuids   string[]  optional  

The list of ServicePlans to be associated to the ProposalTemplate.

Duplicate

requires authentication

Duplicate a proposal template

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/templates/81e45c1a-98c7-37db-8152-2c0d8c70c851/duplicate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/templates/81e45c1a-98c7-37db-8152-2c0d8c70c851/duplicate';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/templates/81e45c1a-98c7-37db-8152-2c0d8c70c851/duplicate"
);

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

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

Request      

POST api/v1/proposals/templates/{proposalTemplate_uuid}/duplicate

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposalTemplate_uuid   string   

Example: 81e45c1a-98c7-37db-8152-2c0d8c70c851

Show

requires authentication

Show a single proposal template.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/proposals/templates/7e1422aa-d776-3a90-921a-e1de80d1f28b" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/templates/7e1422aa-d776-3a90-921a-e1de80d1f28b';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/templates/7e1422aa-d776-3a90-921a-e1de80d1f28b"
);

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

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

Request      

GET api/v1/proposals/templates/{proposalTemplate_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposalTemplate_uuid   string   

Example: 7e1422aa-d776-3a90-921a-e1de80d1f28b

Update

requires authentication

Update a proposal template.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/templates/63719a7a-ba33-3e65-9d64-581af14cf8d5" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"company_location_uuid\": \"0f594911-1086-34ea-997c-e53062e1f636\",
    \"title\": \"doloribus\",
    \"description\": \"Magnam beatae atque voluptatibus saepe.\",
    \"settings\": {
        \"attr\": \"value\"
    },
    \"service_plan_uuids\": [
        \"815d3d9c-f371-3781-8456-7e6954b5b0f5\",
        \"815d3d9c-f371-3781-8456-7e6954b5b0f5\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/templates/63719a7a-ba33-3e65-9d64-581af14cf8d5';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'company_location_uuid' => '0f594911-1086-34ea-997c-e53062e1f636',
            'title' => 'doloribus',
            'description' => 'Magnam beatae atque voluptatibus saepe.',
            'settings' => [
                'attr' => 'value',
            ],
            'service_plan_uuids' => [
                '815d3d9c-f371-3781-8456-7e6954b5b0f5',
                '815d3d9c-f371-3781-8456-7e6954b5b0f5',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/templates/63719a7a-ba33-3e65-9d64-581af14cf8d5"
);

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

let body = {
    "company_location_uuid": "0f594911-1086-34ea-997c-e53062e1f636",
    "title": "doloribus",
    "description": "Magnam beatae atque voluptatibus saepe.",
    "settings": {
        "attr": "value"
    },
    "service_plan_uuids": [
        "815d3d9c-f371-3781-8456-7e6954b5b0f5",
        "815d3d9c-f371-3781-8456-7e6954b5b0f5"
    ]
};

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

Request      

PUT api/v1/proposals/templates/{proposalTemplate_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposalTemplate_uuid   string   

Example: 63719a7a-ba33-3e65-9d64-581af14cf8d5

Body Parameters

company_location_uuid   string   

The uuid of company location for proposal template. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 0f594911-1086-34ea-997c-e53062e1f636

title   string   

The name of the proposal template. Example : Proposal Template 1 Example: doloribus

description   string  optional  

The name of the proposal template. Example : This is a sample description Example: Magnam beatae atque voluptatibus saepe.

settings   object  optional  

The attributes of the proposal template.

service_plan_uuids   string[]  optional  

The list of ServicePlans to be associated to the ProposalTemplate.

Patch

requires authentication

Patch a company proposal template.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/templates/02ab967c-5cf2-34b7-9718-cbc4eeda411f" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"company_location_uuid\": \"5e874931-f4d5-3398-a38d-7dd085bb8a81\",
    \"title\": \"architecto\",
    \"description\": \"Non magni soluta est alias ut neque.\",
    \"settings\": {
        \"attr\": \"value\"
    },
    \"service_plan_uuids\": [
        \"815d3d9c-f371-3781-8456-7e6954b5b0f5\",
        \"815d3d9c-f371-3781-8456-7e6954b5b0f5\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/templates/02ab967c-5cf2-34b7-9718-cbc4eeda411f';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'company_location_uuid' => '5e874931-f4d5-3398-a38d-7dd085bb8a81',
            'title' => 'architecto',
            'description' => 'Non magni soluta est alias ut neque.',
            'settings' => [
                'attr' => 'value',
            ],
            'service_plan_uuids' => [
                '815d3d9c-f371-3781-8456-7e6954b5b0f5',
                '815d3d9c-f371-3781-8456-7e6954b5b0f5',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/templates/02ab967c-5cf2-34b7-9718-cbc4eeda411f"
);

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

let body = {
    "company_location_uuid": "5e874931-f4d5-3398-a38d-7dd085bb8a81",
    "title": "architecto",
    "description": "Non magni soluta est alias ut neque.",
    "settings": {
        "attr": "value"
    },
    "service_plan_uuids": [
        "815d3d9c-f371-3781-8456-7e6954b5b0f5",
        "815d3d9c-f371-3781-8456-7e6954b5b0f5"
    ]
};

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

Request      

PATCH api/v1/proposals/templates/{proposalTemplate_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposalTemplate_uuid   string   

Example: 02ab967c-5cf2-34b7-9718-cbc4eeda411f

Body Parameters

company_location_uuid   string  optional  

The uuid of company location for proposal template. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 5e874931-f4d5-3398-a38d-7dd085bb8a81

title   string  optional  

The name of the proposal template. Example : Proposal Template 1 Example: architecto

description   string  optional  

The name of the proposal template. Example : This is a sample description Example: Non magni soluta est alias ut neque.

settings   object  optional  

The attributes of the proposal template.

service_plan_uuids   string[]  optional  

The list of ServicePlans to be associated to the ProposalTemplate.

Delete

requires authentication

Delete a proposal template.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/templates/9f3ddada-ee1d-3403-9f7d-7332b7a239c0" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/templates/9f3ddada-ee1d-3403-9f7d-7332b7a239c0';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/templates/9f3ddada-ee1d-3403-9f7d-7332b7a239c0"
);

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

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

Request      

DELETE api/v1/proposals/templates/{proposalTemplate_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposalTemplate_uuid   string   

Example: 9f3ddada-ee1d-3403-9f7d-7332b7a239c0

Media Item

API for Media Item

List

requires authentication

Shows the list of media items with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/media-items" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"company_uuid\": \"0f1706b4-e1bd-3902-a8d0-5412866000eb\",
    \"company_location_uuid\": \"ec399b09-ade3-3640-8d08-b33ceaf2236c\",
    \"media_source_uuid\": \"58020f08-83d0-33d2-a4c7-c6769e6d42df\",
    \"include_global_files\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-items';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'company_uuid' => '0f1706b4-e1bd-3902-a8d0-5412866000eb',
            'company_location_uuid' => 'ec399b09-ade3-3640-8d08-b33ceaf2236c',
            'media_source_uuid' => '58020f08-83d0-33d2-a4c7-c6769e6d42df',
            'include_global_files' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-items"
);

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

let body = {
    "company_uuid": "0f1706b4-e1bd-3902-a8d0-5412866000eb",
    "company_location_uuid": "ec399b09-ade3-3640-8d08-b33ceaf2236c",
    "media_source_uuid": "58020f08-83d0-33d2-a4c7-c6769e6d42df",
    "include_global_files": true
};

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

Request      

GET api/v1/media-items

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 14

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 3

sort_by   string  optional  

The column name. Example : name Example: perferendis

sort_order   string  optional  

The order in which you want your records. Example : asc Example: in

search   string  optional  

The general search, it will find matching string. Example : home Example: dolorem

Body Parameters

types   object  optional  
Must be one of:
  • AUDIO
  • IMAGE
  • VIDEO
  • DOCUMENT
  • EMBED
media_tag_names   object  optional  
company_uuid   string  optional  

Must be a valid UUID. Example: 0f1706b4-e1bd-3902-a8d0-5412866000eb

companies_uuid   object  optional  
company_location_uuid   string  optional  

Must be a valid UUID. Example: ec399b09-ade3-3640-8d08-b33ceaf2236c

company_locations_uuid   object  optional  
media_source_uuid   string  optional  

Must be a valid UUID. Example: 58020f08-83d0-33d2-a4c7-c6769e6d42df

include_global_files   boolean  optional  

Example: true

Show

requires authentication

Show a single media item

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/media-items/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-items/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-items/1"
);

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

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

Request      

GET api/v1/media-items/{mediaItem_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaItem_uuid   integer   

Example: 1

Store

requires authentication

Upload a media item

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/media-items" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "name=libero"\
    --form "description=At velit aliquam culpa et maxime."\
    --form "directory=proposal-template"\
    --form "type=document"\
    --form "fileUpload=@/tmp/phpHkfEHP" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-items';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'name',
                'contents' => 'libero'
            ],
            [
                'name' => 'description',
                'contents' => 'At velit aliquam culpa et maxime.'
            ],
            [
                'name' => 'directory',
                'contents' => 'proposal-template'
            ],
            [
                'name' => 'type',
                'contents' => 'document'
            ],
            [
                'name' => 'fileUpload',
                'contents' => fopen('/tmp/phpHkfEHP', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-items"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('name', 'libero');
body.append('description', 'At velit aliquam culpa et maxime.');
body.append('directory', 'proposal-template');
body.append('type', 'document');
body.append('fileUpload', document.querySelector('input[name="fileUpload"]').files[0]);

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

Request      

POST api/v1/media-items

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

Body Parameters

name   string  optional  

The name of the file. Example : MyFile.txt Example: libero

description   string  optional  

The description of the file. Example : This is a sample description for uploaded file Example: At velit aliquam culpa et maxime.

directory   string   

The directory where the file will be located. Example: proposal-template

type   string   

The type of the file (in: image, document). Example: document

fileUpload   file   

The file to be uploaded. Example: /tmp/phpHkfEHP

Update

requires authentication

Update a media item.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/media-items/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"et\",
    \"description\": \"Atque in sit nulla.\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-items/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'et',
            'description' => 'Atque in sit nulla.',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-items/1"
);

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

let body = {
    "name": "et",
    "description": "Atque in sit nulla."
};

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

Request      

PUT api/v1/media-items/{mediaItem_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaItem_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the media item. Example : "My media item" Example: et

description   string  optional  

The description of the media item. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: Atque in sit nulla.

Patch

requires authentication

Patch a media item.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/media-items/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"ut\",
    \"description\": \"Id harum expedita sapiente cum totam eum laborum magnam.\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-items/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'ut',
            'description' => 'Id harum expedita sapiente cum totam eum laborum magnam.',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-items/1"
);

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

let body = {
    "name": "ut",
    "description": "Id harum expedita sapiente cum totam eum laborum magnam."
};

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

Request      

PATCH api/v1/media-items/{mediaItem_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaItem_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the media item. Example : "My media item" Example: ut

description   string  optional  

The description of the media item. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: Id harum expedita sapiente cum totam eum laborum magnam.

Delete

requires authentication

Delete a media item.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/media-items/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/media-items/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/media-items/1"
);

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

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

Request      

DELETE api/v1/media-items/{mediaItem_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

mediaItem_uuid   integer   

Example: 1

Company Product

API for company product details

List

requires authentication

Shows the list of company products with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/products" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/products';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/products"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/products

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 3

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 10

sort_by   string  optional  

The column name. Example : name Example: nesciunt

sort_order   string  optional  

The order in which you want your records. Example : asc Example: similique

search   string  optional  

The general search, it will find matching string. Example : home Example: incidunt

Show

requires authentication

Show a single company product.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/products/512adc80-5131-3c40-aff2-9c213db8289b" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/products/512adc80-5131-3c40-aff2-9c213db8289b';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/products/512adc80-5131-3c40-aff2-9c213db8289b"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/products/{companyProduct_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyProduct_uuid   string   

Example: 512adc80-5131-3c40-aff2-9c213db8289b

Store

requires authentication

Store a newly created company product.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/products" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"occaecati\",
    \"product_attributes\": {
        \"attr\": \"value\"
    },
    \"label_image_url\": \"http:\\/\\/smarterlaunch.local\\/image1.jpg\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/products';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'occaecati',
            'product_attributes' => [
                'attr' => 'value',
            ],
            'label_image_url' => 'http://smarterlaunch.local/image1.jpg',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/products"
);

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

let body = {
    "name": "occaecati",
    "product_attributes": {
        "attr": "value"
    },
    "label_image_url": "http:\/\/smarterlaunch.local\/image1.jpg"
};

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

Request      

POST api/v1/companies/{company_uuid}/products

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the product. Example : Product 1 Example: occaecati

product_attributes   object   

The attributes of the product.

label_image_url   string  optional  

optional The image url of the product. Example: http://smarterlaunch.local/image1.jpg

Update

requires authentication

Update a company product.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/products/ff31b743-e0e2-3d21-941a-4b2c45da2482" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"reprehenderit\",
    \"product_attributes\": {
        \"attr\": \"value\"
    },
    \"label_image_url\": \"http:\\/\\/smarterlaunch.local\\/image1.jpg\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/products/ff31b743-e0e2-3d21-941a-4b2c45da2482';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'reprehenderit',
            'product_attributes' => [
                'attr' => 'value',
            ],
            'label_image_url' => 'http://smarterlaunch.local/image1.jpg',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/products/ff31b743-e0e2-3d21-941a-4b2c45da2482"
);

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

let body = {
    "name": "reprehenderit",
    "product_attributes": {
        "attr": "value"
    },
    "label_image_url": "http:\/\/smarterlaunch.local\/image1.jpg"
};

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

Request      

PUT api/v1/companies/{company_uuid}/products/{companyProduct_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyProduct_uuid   string   

Example: ff31b743-e0e2-3d21-941a-4b2c45da2482

Body Parameters

name   string   

The name of the product. Example : Product 1 Example: reprehenderit

product_attributes   object   

The attributes of the product.

label_image_url   string  optional  

optional The image url of the product. Example: http://smarterlaunch.local/image1.jpg

Patch

requires authentication

Patch a company product.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/products/10c0e90d-9b82-32fc-9b11-04c2a9319140" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"rem\",
    \"product_attributes\": {
        \"attr\": \"value\"
    },
    \"label_image_url\": \"http:\\/\\/smarterlaunch.local\\/image1.jpg\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/products/10c0e90d-9b82-32fc-9b11-04c2a9319140';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'rem',
            'product_attributes' => [
                'attr' => 'value',
            ],
            'label_image_url' => 'http://smarterlaunch.local/image1.jpg',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/products/10c0e90d-9b82-32fc-9b11-04c2a9319140"
);

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

let body = {
    "name": "rem",
    "product_attributes": {
        "attr": "value"
    },
    "label_image_url": "http:\/\/smarterlaunch.local\/image1.jpg"
};

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

Request      

PATCH api/v1/companies/{company_uuid}/products/{companyProduct_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyProduct_uuid   string   

Example: 10c0e90d-9b82-32fc-9b11-04c2a9319140

Body Parameters

name   string  optional  

optional The name of the product. Example : Product 1 Example: rem

product_attributes   object  optional  

optional The attributes of the product.

label_image_url   string  optional  

optional The image url of the product. Example: http://smarterlaunch.local/image1.jpg

Delete

requires authentication

Delete a product.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/products/0faa1b0e-80aa-3eb7-a2ee-549652130c46" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/products/0faa1b0e-80aa-3eb7-a2ee-549652130c46';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/products/0faa1b0e-80aa-3eb7-a2ee-549652130c46"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/products/{companyProduct_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyProduct_uuid   string   

Example: 0faa1b0e-80aa-3eb7-a2ee-549652130c46

Tag

API for Tag

List

requires authentication

Shows the list of tags with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/import-set-tags" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/import-set-tags';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/import-set-tags"
);

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

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

Request      

GET api/v1/import-set-tags

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 1

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 6

sort_by   string  optional  

The column name. Example : name Example: voluptatem

sort_order   string  optional  

The order in which you want your records. Example : asc Example: placeat

search   string  optional  

The general search, it will find matching string. Example : "Pest Control" Example: vitae

Permission

API for permission details

List / Fetch

requires authentication

Shows the list of permission or fetch single record using uuid.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/permissions" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\",
    \"name\": \"user-list\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/permissions';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
            'name' => 'user-list',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/permissions"
);

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

let body = {
    "uuid": "3245d630-24fd-11ec-accd-e397aec85c7f",
    "name": "user-list"
};

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

Request      

GET api/v1/permissions

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

uuid   string  optional  

optional The uuid of the permission. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

name   string   

The name of the permission. Example: user-list

List / Fetch

requires authentication

Shows the list of permission or fetch single record using uuid.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/permissions/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\",
    \"name\": \"user-list\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/permissions/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
            'name' => 'user-list',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/permissions/1"
);

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

let body = {
    "uuid": "3245d630-24fd-11ec-accd-e397aec85c7f",
    "name": "user-list"
};

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

Request      

GET api/v1/permissions/{permissionUuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

permissionUuid   integer   

Example: 1

Body Parameters

uuid   string  optional  

optional The uuid of the permission. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

name   string   

The name of the permission. Example: user-list

Create / Update permission.

requires authentication

This endpoint lets user to create/update permission.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/permissions" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"user-list\",
    \"uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/permissions';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'user-list',
            'uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/permissions"
);

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

let body = {
    "name": "user-list",
    "uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4"
};

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

Request      

POST api/v1/permissions

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

name   string   

The name of the permission. Example: user-list

uuid   string  optional  

optional The uuid of the permission. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

Create / Update permission.

requires authentication

This endpoint lets user to create/update permission.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/permissions/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"user-list\",
    \"uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/permissions/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'user-list',
            'uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/permissions/1"
);

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

let body = {
    "name": "user-list",
    "uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4"
};

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

Request      

PUT api/v1/permissions/{permissionUuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

permissionUuid   integer   

Example: 1

Body Parameters

name   string   

The name of the permission. Example: user-list

uuid   string  optional  

optional The uuid of the permission. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

Delete

requires authentication

This endpoint allows user to delete permission.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/permissions/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/permissions/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/permissions/1"
);

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

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

Request      

DELETE api/v1/permissions/{permissionUuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

permissionUuid   integer   

Example: 1

uuid   string   

The uuid of the permission. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Company File

API for Company File

Store

requires authentication

Upload a file into a company

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/files" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "name=et"\
    --form "description=Impedit nesciunt incidunt dignissimos et."\
    --form "directory=proposal-template"\
    --form "type=document"\
    --form "fileUpload=@/tmp/phpYgheQR" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/files';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'name',
                'contents' => 'et'
            ],
            [
                'name' => 'description',
                'contents' => 'Impedit nesciunt incidunt dignissimos et.'
            ],
            [
                'name' => 'directory',
                'contents' => 'proposal-template'
            ],
            [
                'name' => 'type',
                'contents' => 'document'
            ],
            [
                'name' => 'fileUpload',
                'contents' => fopen('/tmp/phpYgheQR', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/files"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('name', 'et');
body.append('description', 'Impedit nesciunt incidunt dignissimos et.');
body.append('directory', 'proposal-template');
body.append('type', 'document');
body.append('fileUpload', document.querySelector('input[name="fileUpload"]').files[0]);

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

Request      

POST api/v1/companies/{company_uuid}/files

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string  optional  

The name of the file. Example : MyFile.txt Example: et

description   string  optional  

The description of the file. Example : This is a sample description for uploaded file Example: Impedit nesciunt incidunt dignissimos et.

directory   string   

The directory where the file will be located. Example: proposal-template

type   string   

The type of the file (in: image, document). Example: document

fileUpload   file   

The file to be uploaded. Example: /tmp/phpYgheQR

Delete

requires authentication

Delete a file from a company

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/files" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"file_url\": \"http:\\/\\/collier.net\\/magnam-voluptas-sapiente-quia-quia-ut-ratione-unde.html\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/files';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'file_url' => 'http://collier.net/magnam-voluptas-sapiente-quia-quia-ut-ratione-unde.html',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/files"
);

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

let body = {
    "file_url": "http:\/\/collier.net\/magnam-voluptas-sapiente-quia-quia-ut-ratione-unde.html"
};

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

Request      

DELETE api/v1/companies/{company_uuid}/files

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

file_url   string  optional  

or array The url of the file. Example : MyFile.txt Example: http://collier.net/magnam-voluptas-sapiente-quia-quia-ut-ratione-unde.html

Country

API for country details

List / Fetch

Shows the list of country or fetch single record using uuid.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/countries" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\",
    \"name\": \"baroda\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/countries';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
            'name' => 'baroda',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/countries"
);

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

let body = {
    "uuid": "3245d630-24fd-11ec-accd-e397aec85c7f",
    "name": "baroda"
};

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

Request      

GET api/v1/countries

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

uuid   string  optional  

optional The country uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

name   string  optional  

optional The country name. Example: baroda

List / Fetch

Shows the list of country or fetch single record using uuid.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/countries/d0f09c7e-1b5e-3cd9-a843-7dde24068c41" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\",
    \"name\": \"baroda\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/countries/d0f09c7e-1b5e-3cd9-a843-7dde24068c41';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
            'name' => 'baroda',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/countries/d0f09c7e-1b5e-3cd9-a843-7dde24068c41"
);

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

let body = {
    "uuid": "3245d630-24fd-11ec-accd-e397aec85c7f",
    "name": "baroda"
};

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

Request      

GET api/v1/countries/{countryUuid}

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

countryUuid   string   

Example: d0f09c7e-1b5e-3cd9-a843-7dde24068c41

Body Parameters

uuid   string  optional  

optional The country uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

name   string  optional  

optional The country name. Example: baroda

Get country states using country uuid.

Shows the list of states using country uuid.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/countries/96e241e6-fb34-3a13-9cdb-b994bcd0d3eb/states" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/countries/96e241e6-fb34-3a13-9cdb-b994bcd0d3eb/states';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/countries/96e241e6-fb34-3a13-9cdb-b994bcd0d3eb/states"
);

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

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

Request      

GET api/v1/countries/{countryUuid}/states

Headers

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

countryUuid   string   

Example: 96e241e6-fb34-3a13-9cdb-b994bcd0d3eb

country_uuid   string   

The country uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Solution Category

API for Solution Category

List

requires authentication

Shows the list of solution categories.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/solution-categories" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"include_fields\": [
        \"user_progress\"
    ],
    \"ignore_cached\": false
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solution-categories';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'include_fields' => [
                'user_progress',
            ],
            'ignore_cached' => false,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories"
);

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

let body = {
    "include_fields": [
        "user_progress"
    ],
    "ignore_cached": false
};

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

Request      

GET api/v1/solution-categories

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 20

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 10

sort_by   string  optional  

The column name. Example : name Example: sunt

sort_order   string  optional  

The order in which you want your records. Example : asc Example: distinctio

search   string  optional  

The general search, it will find matching string. Example : home Example: sit

filter_by_parent_solution_category_uuids   string  optional  

array To filter the list of solution categories by parent solution category. Example : ["3c787d66-2a4f-3f1d-9591-c330be0abe82"] Example: et

Body Parameters

include_fields   string[]  optional  
Must be one of:
  • user_progress
  • solutions
ignore_cached   boolean  optional  

Example: false

Show

requires authentication

Show a single solution category.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solution-categories/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1"
);

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

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

Request      

GET api/v1/solution-categories/{solutionCategory_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solutionCategory_uuid   integer   

Example: 1

Store

requires authentication

Store a new solution category.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"est\",
    \"description\": \"\\\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\\\"\",
    \"parent_solution_category_uuid\": \"\\\"3c787d66-2a4f-3f1d-9591-c330be0abe82\\\"\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solution-categories';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'est',
            'description' => '"Lorem ipsum dolor sit amet consectetur adipisicing elit."',
            'parent_solution_category_uuid' => '"3c787d66-2a4f-3f1d-9591-c330be0abe82"',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories"
);

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

let body = {
    "name": "est",
    "description": "\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\"",
    "parent_solution_category_uuid": "\"3c787d66-2a4f-3f1d-9591-c330be0abe82\""
};

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

Request      

POST api/v1/solution-categories

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

name   string   

The name of the solution category. Example : Solution Category 1 Example: est

description   string   

The attributes of the solution category. Example: "Lorem ipsum dolor sit amet consectetur adipisicing elit."

parent_solution_category_uuid   string  optional  

optional The parent of the solution category. Example: "3c787d66-2a4f-3f1d-9591-c330be0abe82"

Update

requires authentication

Update a solution category.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"sed\",
    \"description\": \"\\\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\\\"\",
    \"parent_solution_category_uuid\": \"\\\"3c787d66-2a4f-3f1d-9591-c330be0abe82\\\"\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solution-categories/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'sed',
            'description' => '"Lorem ipsum dolor sit amet consectetur adipisicing elit."',
            'parent_solution_category_uuid' => '"3c787d66-2a4f-3f1d-9591-c330be0abe82"',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1"
);

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

let body = {
    "name": "sed",
    "description": "\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\"",
    "parent_solution_category_uuid": "\"3c787d66-2a4f-3f1d-9591-c330be0abe82\""
};

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

Request      

PUT api/v1/solution-categories/{solutionCategory_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solutionCategory_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the solution category. Example : Proposal Creation Example: sed

description   string   

The attributes of the solution category. Example: "Lorem ipsum dolor sit amet consectetur adipisicing elit."

parent_solution_category_uuid   string  optional  

optional The parent of the solution category. Example: "3c787d66-2a4f-3f1d-9591-c330be0abe82"

Reset

requires authentication

Reset a solution category user progress.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1/reset" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solution-categories/1/reset';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1/reset"
);

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

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

Request      

PUT api/v1/solution-categories/{solutionCategory_uuid}/reset

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solutionCategory_uuid   integer   

Example: 1

Update user progress

requires authentication

Update user progress.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1/user-progress" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"is_completed\": true,
    \"step\": []
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solution-categories/1/user-progress';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'is_completed' => true,
            'step' => [],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1/user-progress"
);

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

let body = {
    "is_completed": true,
    "step": []
};

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

Request      

PUT api/v1/solution-categories/{solutionCategory_uuid}/user-progress

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solutionCategory_uuid   integer   

Example: 1

Body Parameters

is_completed   boolean  optional  

The solution category of the solution. Example : false Example: true

step   object  optional  

The current step the use is on. Example : 2

Patch Index

requires authentication

Performs specific updates for solution categories

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1/sort" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solution-categories/1/sort';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1/sort"
);

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

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

Request      

PATCH api/v1/solution-categories/{solutionCategory_uuid}/sort

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solutionCategory_uuid   integer   

Example: 1

solution_categories_ranking_list   string  optional  

string[] A dictionary of uuids with uuid as key and rank as the value. Example : {"69e56cdf-cea8-4356-b35d-58d610aba886" : 1, "9c578b77-916a-4620-a246-fa951f422912" : 2} Example: quia

Patch

requires authentication

Patch a solution category.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"tenetur\",
    \"description\": \"\\\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\\\"\",
    \"parent_solution_category_uuid\": \"\\\"3c787d66-2a4f-3f1d-9591-c330be0abe82\\\"\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solution-categories/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'tenetur',
            'description' => '"Lorem ipsum dolor sit amet consectetur adipisicing elit."',
            'parent_solution_category_uuid' => '"3c787d66-2a4f-3f1d-9591-c330be0abe82"',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1"
);

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

let body = {
    "name": "tenetur",
    "description": "\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\"",
    "parent_solution_category_uuid": "\"3c787d66-2a4f-3f1d-9591-c330be0abe82\""
};

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

Request      

PATCH api/v1/solution-categories/{solutionCategory_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solutionCategory_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the solution category. Example : Proposal Creation Example: tenetur

description   string   

The attributes of the solution category. Example: "Lorem ipsum dolor sit amet consectetur adipisicing elit."

parent_solution_category_uuid   string  optional  

optional The parent of the solution category. Example: "3c787d66-2a4f-3f1d-9591-c330be0abe82"

Delete

requires authentication

Delete a solution category.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solution-categories/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solution-categories/1"
);

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

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

Request      

DELETE api/v1/solution-categories/{solutionCategory_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solutionCategory_uuid   integer   

Example: 1

Solution Feedback

API for Solution Feedback

List

requires authentication

Shows the list of solution feedbacks.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback"
);

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

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

Request      

GET api/v1/solutions/{solution_uuid}/feedback

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solution_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 17

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 7

sort_by   string  optional  

The column name. Example : name Example: alias

sort_order   string  optional  

The order in which you want your records. Example : asc Example: molestiae

search   string  optional  

The general search, it will find matching string. Example : home Example: vel

Show

requires authentication

Show a single solution.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback/581c5326-3131-3213-96ca-891a61bfdb3f" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback/581c5326-3131-3213-96ca-891a61bfdb3f';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback/581c5326-3131-3213-96ca-891a61bfdb3f"
);

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

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

Request      

GET api/v1/solutions/{solution_uuid}/feedback/{solutionFeedback_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solution_uuid   integer   

Example: 1

solutionFeedback_uuid   string   

Example: 581c5326-3131-3213-96ca-891a61bfdb3f

Store

requires authentication

Store a new solution feedback.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"rate\": 16,
    \"feedback\": \"\\\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\\\"\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'rate' => 16,
            'feedback' => '"Lorem ipsum dolor sit amet consectetur adipisicing elit."',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback"
);

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

let body = {
    "rate": 16,
    "feedback": "\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\""
};

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

Request      

POST api/v1/solutions/{solution_uuid}/feedback

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solution_uuid   integer   

Example: 1

Body Parameters

rate   integer   

The name of the solution. Example : 5 Example: 16

feedback   string  optional  

The attributes of the solution. Example: "Lorem ipsum dolor sit amet consectetur adipisicing elit."

Update

requires authentication

Update a solution .

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback/cbe0d6e7-df9f-3e1a-9b99-28ee834337f5" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"rate\": 10,
    \"feedback\": \"\\\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\\\"\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback/cbe0d6e7-df9f-3e1a-9b99-28ee834337f5';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'rate' => 10,
            'feedback' => '"Lorem ipsum dolor sit amet consectetur adipisicing elit."',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback/cbe0d6e7-df9f-3e1a-9b99-28ee834337f5"
);

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

let body = {
    "rate": 10,
    "feedback": "\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\""
};

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

Request      

PUT api/v1/solutions/{solution_uuid}/feedback/{solutionFeedback_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solution_uuid   integer   

Example: 1

solutionFeedback_uuid   string   

Example: cbe0d6e7-df9f-3e1a-9b99-28ee834337f5

Body Parameters

rate   integer   

The name of the solution. Example : 5 Example: 10

feedback   string  optional  

The attributes of the solution. Example: "Lorem ipsum dolor sit amet consectetur adipisicing elit."

Patch

requires authentication

Patch a solution feedback.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback/278897ee-032d-3867-8ad3-8b0672c4281c" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"rate\": 16,
    \"feedback\": \"\\\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\\\"\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback/278897ee-032d-3867-8ad3-8b0672c4281c';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'rate' => 16,
            'feedback' => '"Lorem ipsum dolor sit amet consectetur adipisicing elit."',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback/278897ee-032d-3867-8ad3-8b0672c4281c"
);

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

let body = {
    "rate": 16,
    "feedback": "\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\""
};

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

Request      

PATCH api/v1/solutions/{solution_uuid}/feedback/{solutionFeedback_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solution_uuid   integer   

Example: 1

solutionFeedback_uuid   string   

Example: 278897ee-032d-3867-8ad3-8b0672c4281c

Body Parameters

rate   integer   

The name of the solution. Example : 5 Example: 16

feedback   string  optional  

The attributes of the solution. Example: "Lorem ipsum dolor sit amet consectetur adipisicing elit."

Delete

requires authentication

Remove the specified resource from storage.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback/c3a2be71-dbce-3cc0-bef7-435e77d16577" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback/c3a2be71-dbce-3cc0-bef7-435e77d16577';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/feedback/c3a2be71-dbce-3cc0-bef7-435e77d16577"
);

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

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

Request      

DELETE api/v1/solutions/{solution_uuid}/feedback/{solutionFeedback_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solution_uuid   integer   

Example: 1

solutionFeedback_uuid   string   

Example: c3a2be71-dbce-3cc0-bef7-435e77d16577

Company Users

API for company details

List

requires authentication

Shows the list of company users that the user has access to view.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/users?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ignore_cached\": true,
    \"should_reset_cache\": false,
    \"page_size\": 15,
    \"sort_by\": \"display_name\",
    \"sort_order\": \"asc\",
    \"search\": \"John\",
    \"filter_by_status_code\": \"STATUS_ACTIVE \\/ [\\\"STATUS_ACTIVE\\\".\\\"STATUS_DISABLED\\\"]\",
    \"filter_by_role_code\": \"ROLE_COMPANY_MANAGER\",
    \"filter_by_company_location_uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/users';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'ignore_cached' => true,
            'should_reset_cache' => false,
            'page_size' => 15,
            'sort_by' => 'display_name',
            'sort_order' => 'asc',
            'search' => 'John',
            'filter_by_status_code' => 'STATUS_ACTIVE / ["STATUS_ACTIVE"."STATUS_DISABLED"]',
            'filter_by_role_code' => 'ROLE_COMPANY_MANAGER',
            'filter_by_company_location_uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "ignore_cached": true,
    "should_reset_cache": false,
    "page_size": 15,
    "sort_by": "display_name",
    "sort_order": "asc",
    "search": "John",
    "filter_by_status_code": "STATUS_ACTIVE \/ [\"STATUS_ACTIVE\".\"STATUS_DISABLED\"]",
    "filter_by_role_code": "ROLE_COMPANY_MANAGER",
    "filter_by_company_location_uuid": "3245d630-24fd-11ec-accd-e397aec85c7f"
};

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

Request      

GET api/v1/companies/{company_uuid}/users

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyUuid   string   

The company uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Query Parameters

page   integer  optional  

optional The page number. Example: 1

Body Parameters

include_fields   string[]  optional  
ignore_cached   boolean  optional  

Example: true

should_reset_cache   boolean  optional  

optional Resets the cache Example: false

page_size   integer  optional  

optional The number of records you want per page. Example: 15

sort_by   string  optional  

optional The column name. Example: display_name

sort_order   string  optional  

optional The order in which you want your records. Example: asc

search   string  optional  

optional The general search, it will find matching string. Example: John

filter_by_status_code   string/array  optional  

optional Filter results by user status. Example: STATUS_ACTIVE / ["STATUS_ACTIVE"."STATUS_DISABLED"]

filter_by_role_code   string  optional  

optional Filter results by user role. Example: ROLE_COMPANY_MANAGER

filter_by_company_location_uuid   string  optional  

uuid optional Filter results by company location uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Show

requires authentication

Shows detail of a specific company user

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/users/{userOrUserInviteUuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

userOrUserInviteUuid   integer   

Example: 3

Send invitation to user.

requires authentication

This endpoint lets company owner to send invite to its sub-user.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"first_name\": \"John\",
    \"email\": \"hello@smarterlaunch.com\",
    \"role_uuid\": \"45955590-4152-11ec-9c77-2181a8ee04db\",
    \"company_locations\": [],
    \"last_name\": \"Smith\",
    \"company_locations[]\": \"[\\\"45955590-4152-11ec-9c77-2181a8ee04db\\\"]\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/users';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'first_name' => 'John',
            'email' => 'hello@smarterlaunch.com',
            'role_uuid' => '45955590-4152-11ec-9c77-2181a8ee04db',
            'company_locations' => [],
            'last_name' => 'Smith',
            'company_locations[]' => '["45955590-4152-11ec-9c77-2181a8ee04db"]',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users"
);

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

let body = {
    "first_name": "John",
    "email": "hello@smarterlaunch.com",
    "role_uuid": "45955590-4152-11ec-9c77-2181a8ee04db",
    "company_locations": [],
    "last_name": "Smith",
    "company_locations[]": "[\"45955590-4152-11ec-9c77-2181a8ee04db\"]"
};

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

Request      

POST api/v1/companies/{company_uuid}/users

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

first_name   string   

The first name of the user. Example: John

email   string   

The email of the user. Example: hello@smarterlaunch.com

role_uuid   string  optional  

uuid required The role uuid of the user. Example: 45955590-4152-11ec-9c77-2181a8ee04db

company_locations   object   
last_name   string   

The first name of the user. Example: Smith

company_locations[]   string  optional  

uuid of The company location. Example: ["45955590-4152-11ec-9c77-2181a8ee04db"]

Resend invitation to user.

requires authentication

This endpoint lets company owner to send invite to its sub-user.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3245d630-24fd-11ec-accd-e397aec85c7f" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3245d630-24fd-11ec-accd-e397aec85c7f';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3245d630-24fd-11ec-accd-e397aec85c7f"
);

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

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

Request      

POST api/v1/companies/{company_uuid}/users/{uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

uuid   string   

The invited user uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Force activate user

requires authentication

This endpoint lets admin/super admin to activate user.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3/activate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3/activate';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3/activate"
);

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

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

Request      

POST api/v1/companies/{company_uuid}/users/{userInviteUuid}/activate

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

userInviteUuid   integer   

Example: 3

uuid   string   

The invited user uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Update

requires authentication

This endpoint lets the user update company user.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"first_name\": \"John\",
    \"last_name\": \"Smith\",
    \"email\": \"hello@smarterlaunch.com\",
    \"role_uuid\": \"45955590-4152-11ec-9c77-2181a8ee04db\",
    \"company_locations\": [
        \"3245d630-24fd-11ec-accd-e397aec85c7f\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'first_name' => 'John',
            'last_name' => 'Smith',
            'email' => 'hello@smarterlaunch.com',
            'role_uuid' => '45955590-4152-11ec-9c77-2181a8ee04db',
            'company_locations' => [
                '3245d630-24fd-11ec-accd-e397aec85c7f',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3"
);

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

let body = {
    "first_name": "John",
    "last_name": "Smith",
    "email": "hello@smarterlaunch.com",
    "role_uuid": "45955590-4152-11ec-9c77-2181a8ee04db",
    "company_locations": [
        "3245d630-24fd-11ec-accd-e397aec85c7f"
    ]
};

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

Request      

PUT api/v1/companies/{company_uuid}/users/{userUuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

userUuid   integer   

Example: 3

Body Parameters

first_name   string   

The first name of the user. Example: John

last_name   string   

The first name of the user. Example: Smith

email   string   

The email of the user. Example: hello@smarterlaunch.com

role_uuid   string  optional  

uuid required The role uuid of the user. Example: 45955590-4152-11ec-9c77-2181a8ee04db

company_locations   object[]  optional  

array of uuid required The company location.

Patch

requires authentication

This endpoint lets the user patch company user.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"first_name\": \"John\",
    \"role_uuid\": \"45955590-4152-11ec-9c77-2181a8ee04db\",
    \"company_locations\": [
        \"3245d630-24fd-11ec-accd-e397aec85c7f\"
    ],
    \"status_uuid\": \"61fc278a-a23b-3b5b-8ea2-81e901f29e54\",
    \"last_name\": \"Smith\",
    \"email\": \"hello@smarterlaunch.com\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'first_name' => 'John',
            'role_uuid' => '45955590-4152-11ec-9c77-2181a8ee04db',
            'company_locations' => [
                '3245d630-24fd-11ec-accd-e397aec85c7f',
            ],
            'status_uuid' => '61fc278a-a23b-3b5b-8ea2-81e901f29e54',
            'last_name' => 'Smith',
            'email' => 'hello@smarterlaunch.com',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3"
);

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

let body = {
    "first_name": "John",
    "role_uuid": "45955590-4152-11ec-9c77-2181a8ee04db",
    "company_locations": [
        "3245d630-24fd-11ec-accd-e397aec85c7f"
    ],
    "status_uuid": "61fc278a-a23b-3b5b-8ea2-81e901f29e54",
    "last_name": "Smith",
    "email": "hello@smarterlaunch.com"
};

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

Request      

PATCH api/v1/companies/{company_uuid}/users/{userUuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

userUuid   integer   

Example: 3

Body Parameters

first_name   string   

The first name of the user. Example: John

role_uuid   string  optional  

uuid required The role uuid of the user. Example: 45955590-4152-11ec-9c77-2181a8ee04db

company_locations   object[]  optional  

array of uuid required The company location.

status_uuid   string  optional  

Must be a valid UUID. Example: 61fc278a-a23b-3b5b-8ea2-81e901f29e54

last_name   string   

The first name of the user. Example: Smith

email   string   

The email of the user. Example: hello@smarterlaunch.com

Delete

requires authentication

This endpoint allows owner to delete a user.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3245d630-24fd-11ec-accd-e397aec85c7f" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3245d630-24fd-11ec-accd-e397aec85c7f';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/users/3245d630-24fd-11ec-accd-e397aec85c7f"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/users/{userUuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

userUuid   string   

The uuid of the company user to be removed. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

companyUuid   string   

The uuid of the company. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Company Field Group

API for Company field group details

List

requires authentication

Shows the list of company custom field groups with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/custom-field-groups

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 7

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 17

sort_by   string  optional  

The column name. Example : name Example: doloribus

sort_order   string  optional  

The order in which you want your records. Example : asc Example: aspernatur

search   string  optional  

The general search, it will find matching string. Example : home Example: cum

with_trashed   string  optional  

boolean To display soft deleted data as well. Example : true Example: itaque

assignment   string  optional  

To filter data by assignment. Example : CUSTOMER_ADDRESS Example: provident

Show

requires authentication

Show a single company custom field group.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups/892b34bd-6f8a-37eb-aca8-ed1812faacda" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups/892b34bd-6f8a-37eb-aca8-ed1812faacda';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups/892b34bd-6f8a-37eb-aca8-ed1812faacda"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/custom-field-groups/{companyCustomFieldGroup_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyCustomFieldGroup_uuid   string   

Example: 892b34bd-6f8a-37eb-aca8-ed1812faacda

Store

requires authentication

Store a newly created company custom field group.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"illo\",
    \"assignment\": \"rerum\",
    \"company_custom_fields\": [
        \"unde\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'illo',
            'assignment' => 'rerum',
            'company_custom_fields' => [
                'unde',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups"
);

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

let body = {
    "name": "illo",
    "assignment": "rerum",
    "company_custom_fields": [
        "unde"
    ]
};

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

Request      

POST api/v1/companies/{company_uuid}/custom-field-groups

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the custom field group. Example : Additional Details Example: illo

assignment   enum  optional  

CUSTOMER|CUSTOMER_ADDRESS|MY_ACCOUNT|COMPANY|COMPANY_LOCATION required The assignment of the custom field group. Example : CUSTOMER Example: rerum

company_custom_fields   string[]  optional  

of object required The company_custom_fields of the custom field group. Example : [{label: 'Address 3', input_type: 'TEXT}]

Update

requires authentication

Update a company custom field group.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups/7de0dd64-9998-3ae8-a5ec-b49d141d41b2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"nostrum\",
    \"assignment\": \"eligendi\",
    \"company_custom_fields\": [
        \"consequatur\"
    ],
    \"deleted_custom_field_uuids\": [
        \"animi\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups/7de0dd64-9998-3ae8-a5ec-b49d141d41b2';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'nostrum',
            'assignment' => 'eligendi',
            'company_custom_fields' => [
                'consequatur',
            ],
            'deleted_custom_field_uuids' => [
                'animi',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups/7de0dd64-9998-3ae8-a5ec-b49d141d41b2"
);

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

let body = {
    "name": "nostrum",
    "assignment": "eligendi",
    "company_custom_fields": [
        "consequatur"
    ],
    "deleted_custom_field_uuids": [
        "animi"
    ]
};

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

Request      

PUT api/v1/companies/{company_uuid}/custom-field-groups/{companyCustomFieldGroup_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyCustomFieldGroup_uuid   string   

Example: 7de0dd64-9998-3ae8-a5ec-b49d141d41b2

companyCustomFieldGroupUuid   string   

The uuid of the custom field group. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

name   string   

The name of the custom field group. Example : Additional Details Example: nostrum

assignment   enum  optional  

CUSTOMER|CUSTOMER_ADDRESS|MY_ACCOUNT|COMPANY|COMPANY_LOCATION required The assignment of the custom field group. Example : CUSTOMER Example: eligendi

company_custom_fields   string[]  optional  

of object required The company_custom_fields of the custom field group. Example : [{label: 'Address 3', input_type: 'TEXT}]

deleted_custom_field_uuids   string[]  optional  

of uuid required The deleted_custom_field_uuids of the custom field group. Example : ["3245d630-24fd-11ec-accd-e397aec85c7f", "3245d630-24fd-11ec-accd-e397aec85c7f"]

Patch

requires authentication

Patch a company custom field group.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups/0fba50b8-51b9-389c-9962-8a58a695f605" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"et\",
    \"assignment\": \"velit\",
    \"company_custom_fields\": [
        \"voluptatem\"
    ],
    \"deleted_custom_field_uuids\": [
        \"ut\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups/0fba50b8-51b9-389c-9962-8a58a695f605';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'et',
            'assignment' => 'velit',
            'company_custom_fields' => [
                'voluptatem',
            ],
            'deleted_custom_field_uuids' => [
                'ut',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups/0fba50b8-51b9-389c-9962-8a58a695f605"
);

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

let body = {
    "name": "et",
    "assignment": "velit",
    "company_custom_fields": [
        "voluptatem"
    ],
    "deleted_custom_field_uuids": [
        "ut"
    ]
};

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

Request      

PATCH api/v1/companies/{company_uuid}/custom-field-groups/{companyCustomFieldGroup_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyCustomFieldGroup_uuid   string   

Example: 0fba50b8-51b9-389c-9962-8a58a695f605

companyCustomFieldGroupUuid   string   

The uuid of the custom field group. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

name   string   

The name of the custom field group. Example : Additional Details Example: et

assignment   enum  optional  

CUSTOMER|CUSTOMER_ADDRESS|MY_ACCOUNT|COMPANY|COMPANY_LOCATION required The assignment of the custom field group. Example : CUSTOMER Example: velit

company_custom_fields   string[]  optional  

of object required The company_custom_fields of the custom field group. Example : [{label: 'Address 3', input_type: 'TEXT}]

deleted_custom_field_uuids   string[]  optional  

of uuid required The deleted_custom_field_uuids of the custom field group. Example : ["3245d630-24fd-11ec-accd-e397aec85c7f", "3245d630-24fd-11ec-accd-e397aec85c7f"]

Delete

requires authentication

Delete a company custom field group.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups/d85eaead-d284-33b5-993b-2098d1c4adce" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups/d85eaead-d284-33b5-993b-2098d1c4adce';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-field-groups/d85eaead-d284-33b5-993b-2098d1c4adce"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/custom-field-groups/{companyCustomFieldGroup_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyCustomFieldGroup_uuid   string   

Example: d85eaead-d284-33b5-993b-2098d1c4adce

Other Endpoints

POST api/v1/upload-from-url

requires authentication

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/upload-from-url" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"url\": \"http:\\/\\/feest.com\\/est-deleniti-dolorum-excepturi-maiores-autem-autem-ullam.html\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/upload-from-url';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'url' => 'http://feest.com/est-deleniti-dolorum-excepturi-maiores-autem-autem-ullam.html',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/upload-from-url"
);

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

let body = {
    "url": "http:\/\/feest.com\/est-deleniti-dolorum-excepturi-maiores-autem-autem-ullam.html"
};

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

Request      

POST api/v1/upload-from-url

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

url   string   

Must be a valid URL. Example: http://feest.com/est-deleniti-dolorum-excepturi-maiores-autem-autem-ullam.html

POST api/v1/auth/webhook-receiving-url

requires authentication

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/webhook-receiving-url" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/webhook-receiving-url';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/webhook-receiving-url"
);

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

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

Request      

POST api/v1/auth/webhook-receiving-url

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Test

requires authentication

Save new webhook subscription

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/auth/webhooks/subscribe-test" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"url\": \"\'http:\\/\\/zapier.com\\/customer-created-in-smarterlaunch\'\",
    \"event\": \"customer-create\'\",
    \"type\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/auth/webhooks/subscribe-test';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'url' => '\'http://zapier.com/customer-created-in-smarterlaunch\'',
            'event' => 'customer-create\'',
            'type' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/auth/webhooks/subscribe-test"
);

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

let body = {
    "url": "'http:\/\/zapier.com\/customer-created-in-smarterlaunch'",
    "event": "customer-create'",
    "type": true
};

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

Request      

POST api/v1/auth/webhooks/subscribe-test

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

url   string   

The url where smarterlaunch submit data when particular events are triggered. Example: 'http://zapier.com/customer-created-in-smarterlaunch'

event   string   

To determine what kind of trigger the webhook is for. Example: customer-create'

type   boolean   

Check To determine what integration the incoming webhook is for. Example: true

POST Get S3 Pre-signed Url for Proposal Review

requires authentication

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/proposal-file-upload-presigned-url" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"signature_photo\": {
        \"full_path\": \"\\/test\\/signature.png\",
        \"md5_hash\": \"#hash#\",
        \"extension\": \"png\"
    },
    \"proposal_pdf\": {
        \"full_path\": \"\\/test\\/proposal.pdf\",
        \"md5_hash\": \"#hash#\",
        \"extension\": \"pdf\"
    }
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/proposal-file-upload-presigned-url';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'signature_photo' => [
                'full_path' => '/test/signature.png',
                'md5_hash' => '#hash#',
                'extension' => 'png',
            ],
            'proposal_pdf' => [
                'full_path' => '/test/proposal.pdf',
                'md5_hash' => '#hash#',
                'extension' => 'pdf',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/proposal-file-upload-presigned-url"
);

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

let body = {
    "signature_photo": {
        "full_path": "\/test\/signature.png",
        "md5_hash": "#hash#",
        "extension": "png"
    },
    "proposal_pdf": {
        "full_path": "\/test\/proposal.pdf",
        "md5_hash": "#hash#",
        "extension": "pdf"
    }
};

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

Request      

POST api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/proposal-file-upload-presigned-url

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

Body Parameters

signature_photo   object   

The signature image file object {"full_path": string, "md5_hash": string, "extension": string}.

proposal_pdf   object   

The pdf file object {"full_path": string, "md5_hash": string, "extension": string}.

POST Get S3 Pre-signed Url

requires authentication

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/file-upload-presigned-url" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"items[]\": \"[{\\\"path\\\": \\\"\\/companies\\/{company-uuid}\\/\\\", \\\"extension\\\": \\\"jpg\\\"}]\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/file-upload-presigned-url';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'items[]' => '[{"path": "/companies/{company-uuid}/", "extension": "jpg"}]',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/file-upload-presigned-url"
);

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

let body = {
    "items[]": "[{\"path\": \"\/companies\/{company-uuid}\/\", \"extension\": \"jpg\"}]"
};

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

Request      

POST api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/file-upload-presigned-url

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

Body Parameters

items[]   $items  optional  

An array of ['path' => string, 'extension' => string, 'md5_hash' => string, 'is_full_path' => boolean]. Example: [{"path": "/companies/{company-uuid}/", "extension": "jpg"}]

POST Get S3 Pre-signed Url

requires authentication

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/file-upload-presigned-url" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"items[]\": \"[{\\\"path\\\": \\\"\\/companies\\/{company-uuid}\\/\\\", \\\"extension\\\": \\\"jpg\\\"}]\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/file-upload-presigned-url';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'items[]' => '[{"path": "/companies/{company-uuid}/", "extension": "jpg"}]',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/file-upload-presigned-url"
);

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

let body = {
    "items[]": "[{\"path\": \"\/companies\/{company-uuid}\/\", \"extension\": \"jpg\"}]"
};

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

Request      

POST api/v1/file-upload-presigned-url

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

items[]   $items  optional  

An array of ['path' => string, 'extension' => string, 'md5_hash' => string, 'is_full_path' => boolean]. Example: [{"path": "/companies/{company-uuid}/", "extension": "jpg"}]

List

requires authentication

Shows the list of line items with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/line-items

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 3

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 9

sort_by   string  optional  

The column name. Example : name Example: magnam

sort_order   string  optional  

The order in which you want your records. Example : asc Example: voluptatem

search   string  optional  

The general search, it will find matching string. Example : home Example: non

Show

requires authentication

Show a single line item.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/1"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/line-items/{lineItem_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

lineItem_uuid   integer   

Example: 1

Store

requires authentication

Store a new line item.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"eaque\",
    \"description\": \"Tempora ut hic voluptas iste commodi assumenda.\",
    \"line_item_values\": \"et\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'eaque',
            'description' => 'Tempora ut hic voluptas iste commodi assumenda.',
            'line_item_values' => 'et',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items"
);

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

let body = {
    "name": "eaque",
    "description": "Tempora ut hic voluptas iste commodi assumenda.",
    "line_item_values": "et"
};

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

Request      

POST api/v1/companies/{company_uuid}/line-items

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the line item. Example : "Termite Pesticide" Example: eaque

description   string   

The description of the line item. Example : "Termite Pesticide" Example: Tempora ut hic voluptas iste commodi assumenda.

line_item_values   string   

The data of the line item. Example : {"price": [100, 100]} Example: et

Import Set to Line Items

requires authentication

Store a newly created import set.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/import" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"import_files\": \"qui\",
    \"override\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/import';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'import_files' => 'qui',
            'override' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/import"
);

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

let body = {
    "import_files": "qui",
    "override": true
};

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

Request      

POST api/v1/companies/{company_uuid}/line-items/import

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

import_files   files   

The set of json files containing import settings data. Example: qui

override   boolean   

Determine if the import set will replace the current ones with matching names. Example: true

Update

requires authentication

Update a line item.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"sapiente\",
    \"description\": \"Sint iste qui sint neque atque.\",
    \"line_item_values\": \"omnis\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'sapiente',
            'description' => 'Sint iste qui sint neque atque.',
            'line_item_values' => 'omnis',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/1"
);

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

let body = {
    "name": "sapiente",
    "description": "Sint iste qui sint neque atque.",
    "line_item_values": "omnis"
};

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

Request      

PUT api/v1/companies/{company_uuid}/line-items/{lineItem_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

lineItem_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the line item. Example : "Termite Pesticide" Example: sapiente

description   string  optional  

The description of the line item. Example : "Termite Pesticide" Example: Sint iste qui sint neque atque.

line_item_values   string   

The data of the line item. Example : {"price": [100, 100]} Example: omnis

Patch

requires authentication

Update a line item.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"eum\",
    \"description\": \"Magnam provident architecto omnis velit mollitia voluptatem ut.\",
    \"line_item_values\": \"odio\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'eum',
            'description' => 'Magnam provident architecto omnis velit mollitia voluptatem ut.',
            'line_item_values' => 'odio',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/1"
);

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

let body = {
    "name": "eum",
    "description": "Magnam provident architecto omnis velit mollitia voluptatem ut.",
    "line_item_values": "odio"
};

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

Request      

PATCH api/v1/companies/{company_uuid}/line-items/{lineItem_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

lineItem_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the line item. Example : "Termite Pesticide" Example: eum

description   string  optional  

The description of the line item. Example : "Termite Pesticide" Example: Magnam provident architecto omnis velit mollitia voluptatem ut.

line_item_values   string   

The data of the line item. Example : {"price": [100, 100]} Example: odio

Delete

requires authentication

Delete a line item.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/line-items/1"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/line-items/{lineItem_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

lineItem_uuid   integer   

Example: 1

List

requires authentication

Shows the list of teams with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/teams" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/teams';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/teams"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/teams

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 13

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 2

sort_by   string  optional  

The column name. Example : name Example: iste

sort_order   string  optional  

The order in which you want your records. Example : asc Example: enim

search   string  optional  

The general search, it will find matching string. Example : home Example: quo

Show

requires authentication

Show a single team.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/teams/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/teams/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/teams/1"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/teams/{team_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

team_uuid   integer   

Example: 1

Store

requires authentication

Store a newly created team.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/teams" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"voluptas\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/teams';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'voluptas',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/teams"
);

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

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

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

Request      

POST api/v1/companies/{company_uuid}/teams

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the team. Example : "Engineering" Example: voluptas

Update

requires authentication

Update a team.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/teams/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"autem\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/teams/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'autem',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/teams/1"
);

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

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

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

Request      

PUT api/v1/companies/{company_uuid}/teams/{team_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

team_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the team. Example : "Accounting" Example: autem

Patch

requires authentication

Patch a company team.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/teams/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"rerum\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/teams/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'rerum',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/teams/1"
);

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

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

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

Request      

PATCH api/v1/companies/{company_uuid}/teams/{team_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

team_uuid   integer   

Example: 1

Body Parameters

name   string  optional  

The name of the team. Example : "Accounting" Example: rerum

Delete

requires authentication

Delete a team.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/teams/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/teams/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/teams/1"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/teams/{team_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

team_uuid   integer   

Example: 1

List

requires authentication

Returns the list of available reports

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/reports/templates" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/reports/templates';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/reports/templates"
);

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

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

Request      

GET api/v1/reports/templates

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 7

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 15

sort_by   string  optional  

The column name. Example : title Example: repudiandae

sort_order   string  optional  

The order in which you want your records. Example : asc Example: non

search   string  optional  

The general search, it will find matching string. Example : home Example: assumenda

filter_by_uuids   string  optional  

string[] To fitler by selected uuids. Example : [uuid, uuid-2] Example: vero

groups   string  optional  

string[] To fitler by selected groups. Example : [dashboard, sales] Example: ex

uuid   string  optional  

optional The company uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Update

requires authentication

Update a report template.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/reports/templates/169e25d8-bc90-3b8e-ac33-ce9caab5d9f1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/reports/templates/169e25d8-bc90-3b8e-ac33-ce9caab5d9f1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/reports/templates/169e25d8-bc90-3b8e-ac33-ce9caab5d9f1"
);

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

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

Request      

PUT api/v1/reports/templates/{reportTemplate_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

reportTemplate_uuid   string   

Example: 169e25d8-bc90-3b8e-ac33-ce9caab5d9f1

Delete

requires authentication

Delete a report template.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/reports/templates/1551e797-ad4d-3b06-b656-e0e6645536cd" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/reports/templates/1551e797-ad4d-3b06-b656-e0e6645536cd';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/reports/templates/1551e797-ad4d-3b06-b656-e0e6645536cd"
);

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

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

Request      

DELETE api/v1/reports/templates/{reportTemplate_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

reportTemplate_uuid   string   

Example: 1551e797-ad4d-3b06-b656-e0e6645536cd

List

requires authentication

Shows the list of webhooks.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/webhooks/subscribe" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/webhooks/subscribe';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/webhooks/subscribe"
);

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

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

Request      

GET api/v1/webhooks/subscribe

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 2

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 18

sort_by   string  optional  

The column name. Example : name Example: qui

sort_order   string  optional  

The order in which you want your records. Example : asc Example: ut

search   string  optional  

The general search, it will find matching string. Example : home Example: nihil

Store

requires authentication

Save new webhook subscription

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/webhooks/subscribe" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"url\": \"\'http:\\/\\/zapier.com\\/customer-created-in-smarterlaunch\'\",
    \"event\": \"customer-create\'\",
    \"type\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/webhooks/subscribe';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'url' => '\'http://zapier.com/customer-created-in-smarterlaunch\'',
            'event' => 'customer-create\'',
            'type' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/webhooks/subscribe"
);

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

let body = {
    "url": "'http:\/\/zapier.com\/customer-created-in-smarterlaunch'",
    "event": "customer-create'",
    "type": true
};

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

Request      

POST api/v1/webhooks/subscribe

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

url   string   

The url where smarterlaunch submit data when particular events are triggered. Example: 'http://zapier.com/customer-created-in-smarterlaunch'

event   string   

To determine what kind of trigger the webhook is for. Example: customer-create'

type   boolean   

Check To determine what integration the incoming webhook is for. Example: true

Delete

requires authentication

Delete a webhook.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/webhooks/subscribe/3a78ab1e-a993-370e-8487-f56a11447243" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/webhooks/subscribe/3a78ab1e-a993-370e-8487-f56a11447243';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/webhooks/subscribe/3a78ab1e-a993-370e-8487-f56a11447243"
);

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

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

Request      

DELETE api/v1/webhooks/subscribe/{webhook_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

webhook_uuid   string   

Example: 3a78ab1e-a993-370e-8487-f56a11447243

User

API for user details

List / Fetch

requires authentication

Shows the list of users or fetch single record using uuid.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/users" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/users';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/users"
);

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

let body = {
    "uuid": "3245d630-24fd-11ec-accd-e397aec85c7f"
};

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

Request      

GET api/v1/users

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

uuid   string  optional  

optional The uuid of the user. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

List / Fetch

requires authentication

Shows the list of users or fetch single record using uuid.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/users/3" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/users/3';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/users/3"
);

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

let body = {
    "uuid": "3245d630-24fd-11ec-accd-e397aec85c7f"
};

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

Request      

GET api/v1/users/{user_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

user_uuid   integer   

Example: 3

Body Parameters

uuid   string  optional  

optional The uuid of the user. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Store user profile pic.

requires authentication

This endpoint lets user to upload or update profile picture.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/users/3/image" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "uuid=3245d630-24fd-11ec-accd-e397aec85c7f"\
    --form "profile_photo_url=@/tmp/php99UKWR" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/users/3/image';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'uuid',
                'contents' => '3245d630-24fd-11ec-accd-e397aec85c7f'
            ],
            [
                'name' => 'profile_photo_url',
                'contents' => fopen('/tmp/php99UKWR', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/users/3/image"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('uuid', '3245d630-24fd-11ec-accd-e397aec85c7f');
body.append('profile_photo_url', document.querySelector('input[name="profile_photo_url"]').files[0]);

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

Request      

POST api/v1/users/{user_uuid}/image

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

user_uuid   integer   

Example: 3

Body Parameters

profile_photo_url   file   

The image file. Example: /tmp/php99UKWR

uuid   string   

The user uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Store user signature pic.

requires authentication

This endpoint lets user to upload or update signature picture.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/users/3/signature-image" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "uuid=3245d630-24fd-11ec-accd-e397aec85c7f"\
    --form "signature_photo_url=@/tmp/phpqTKd0P" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/users/3/signature-image';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'uuid',
                'contents' => '3245d630-24fd-11ec-accd-e397aec85c7f'
            ],
            [
                'name' => 'signature_photo_url',
                'contents' => fopen('/tmp/phpqTKd0P', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/users/3/signature-image"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('uuid', '3245d630-24fd-11ec-accd-e397aec85c7f');
body.append('signature_photo_url', document.querySelector('input[name="signature_photo_url"]').files[0]);

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

Request      

POST api/v1/users/{user_uuid}/signature-image

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

user_uuid   integer   

Example: 3

Body Parameters

signature_photo_url   file   

The image file. Example: /tmp/phpqTKd0P

uuid   string   

The user uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Create / Update.

requires authentication

This endpoint lets user to create or update single record using uuid

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/users" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "uuid=3245d630-24fd-11ec-accd-e397aec85c7f"\
    --form "first_name=John"\
    --form "last_name=Smith"\
    --form "phone=7897897894"\
    --form "email=hello@smarterlaunch.com"\
    --form "position=Manager"\
    --form "new_password=XXX"\
    --form "confirm_new_password=XTXT"\
    --form "profile_photo_url=@/tmp/php6p9qRS" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/users';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'uuid',
                'contents' => '3245d630-24fd-11ec-accd-e397aec85c7f'
            ],
            [
                'name' => 'first_name',
                'contents' => 'John'
            ],
            [
                'name' => 'last_name',
                'contents' => 'Smith'
            ],
            [
                'name' => 'phone',
                'contents' => '7897897894'
            ],
            [
                'name' => 'email',
                'contents' => 'hello@smarterlaunch.com'
            ],
            [
                'name' => 'position',
                'contents' => 'Manager'
            ],
            [
                'name' => 'new_password',
                'contents' => 'XXX'
            ],
            [
                'name' => 'confirm_new_password',
                'contents' => 'XTXT'
            ],
            [
                'name' => 'profile_photo_url',
                'contents' => fopen('/tmp/php6p9qRS', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/users"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('uuid', '3245d630-24fd-11ec-accd-e397aec85c7f');
body.append('first_name', 'John');
body.append('last_name', 'Smith');
body.append('phone', '7897897894');
body.append('email', 'hello@smarterlaunch.com');
body.append('position', 'Manager');
body.append('new_password', 'XXX');
body.append('confirm_new_password', 'XTXT');
body.append('profile_photo_url', document.querySelector('input[name="profile_photo_url"]').files[0]);

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

Request      

POST api/v1/users

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

Body Parameters

uuid   string  optional  

optional The document uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

first_name   string   

The first name of the customer. Example: John

last_name   string   

The last name of the customer. Example: Smith

phone   string   

The phone of the customer. Example: 7897897894

email   string  optional  

optional The email of the customer. Example: hello@smarterlaunch.com

position   string   

The position of the customer. Example: Manager

new_password   string  optional  

optional The current password of the customer. Example: XXX

confirm_new_password   string  optional  

optional The confirmation of the new password of the customer. Example: XTXT

profile_photo_url   file  optional  

optional The image file. Example: /tmp/php6p9qRS

Create / Update.

requires authentication

This endpoint lets user to create or update single record using uuid

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/users/3" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "uuid=3245d630-24fd-11ec-accd-e397aec85c7f"\
    --form "first_name=John"\
    --form "last_name=Smith"\
    --form "phone=7897897894"\
    --form "email=hello@smarterlaunch.com"\
    --form "position=Manager"\
    --form "new_password=XXX"\
    --form "confirm_new_password=XTXT"\
    --form "profile_photo_url=@/tmp/phpVbDFMS" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/users/3';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'uuid',
                'contents' => '3245d630-24fd-11ec-accd-e397aec85c7f'
            ],
            [
                'name' => 'first_name',
                'contents' => 'John'
            ],
            [
                'name' => 'last_name',
                'contents' => 'Smith'
            ],
            [
                'name' => 'phone',
                'contents' => '7897897894'
            ],
            [
                'name' => 'email',
                'contents' => 'hello@smarterlaunch.com'
            ],
            [
                'name' => 'position',
                'contents' => 'Manager'
            ],
            [
                'name' => 'new_password',
                'contents' => 'XXX'
            ],
            [
                'name' => 'confirm_new_password',
                'contents' => 'XTXT'
            ],
            [
                'name' => 'profile_photo_url',
                'contents' => fopen('/tmp/phpVbDFMS', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/users/3"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('uuid', '3245d630-24fd-11ec-accd-e397aec85c7f');
body.append('first_name', 'John');
body.append('last_name', 'Smith');
body.append('phone', '7897897894');
body.append('email', 'hello@smarterlaunch.com');
body.append('position', 'Manager');
body.append('new_password', 'XXX');
body.append('confirm_new_password', 'XTXT');
body.append('profile_photo_url', document.querySelector('input[name="profile_photo_url"]').files[0]);

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

Request      

PUT api/v1/users/{user_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

user_uuid   integer   

Example: 3

Body Parameters

uuid   string  optional  

optional The document uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

first_name   string   

The first name of the customer. Example: John

last_name   string   

The last name of the customer. Example: Smith

phone   string   

The phone of the customer. Example: 7897897894

email   string  optional  

optional The email of the customer. Example: hello@smarterlaunch.com

position   string   

The position of the customer. Example: Manager

new_password   string  optional  

optional The current password of the customer. Example: XXX

confirm_new_password   string  optional  

optional The confirmation of the new password of the customer. Example: XTXT

profile_photo_url   file  optional  

optional The image file. Example: /tmp/phpVbDFMS

Patch

requires authentication

This endpoint allows users to patch their user info.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/users/3" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"first_name\": \"John\",
    \"last_name\": \"Smith\",
    \"phone\": \"7897897894\",
    \"position\": \"Manager\",
    \"settings\": [
        \"omnis\"
    ],
    \"uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/users/3';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'first_name' => 'John',
            'last_name' => 'Smith',
            'phone' => '7897897894',
            'position' => 'Manager',
            'settings' => [
                'omnis',
            ],
            'uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/users/3"
);

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

let body = {
    "first_name": "John",
    "last_name": "Smith",
    "phone": "7897897894",
    "position": "Manager",
    "settings": [
        "omnis"
    ],
    "uuid": "3245d630-24fd-11ec-accd-e397aec85c7f"
};

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

Request      

PATCH api/v1/users/{user_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

user_uuid   integer   

Example: 3

Body Parameters

first_name   string  optional  

optional The first name of the user. Example: John

last_name   string  optional  

optional The last name of the user. Example: Smith

phone   string  optional  

optional The phone of the user. Example: 7897897894

position   string  optional  

optional The position of the user. Example: Manager

settings   string[]  optional  

optional The user settings.

dark_theme   boolean  optional  

optional The dark theme setting. Example: true

integrations   string[]  optional  

optional The user integrations settings.

isn   string[]  optional  

optional The ISN integration settings.

wisetack   string[]  optional  

optional The Wisetack integration settings.

uuid   string   

The user uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Remove Profile pic.

requires authentication

This endpoint allows users to remove profile pictures with proper authorization.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/users/image" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/users/image';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/users/image"
);

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

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

Request      

DELETE api/v1/users/image

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Remove Profile pic.

requires authentication

This endpoint allows users to remove profile pictures with proper authorization.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/users/3/image" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/users/3/image';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/users/3/image"
);

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

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

Request      

DELETE api/v1/users/{user_uuid}/image

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

user_uuid   integer   

Example: 3

Delete

requires authentication

This end point allows user to delete the user-account.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/users/3" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/users/3';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/users/3"
);

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

let body = {
    "uuid": "3245d630-24fd-11ec-accd-e397aec85c7f"
};

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

Request      

DELETE api/v1/users/{user_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

user_uuid   integer   

Example: 3

Body Parameters

uuid   string   

The uuid of the user. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Company Location Custom Settings

API for company location custom settings

List

requires authentication

Shows the list of do with filter or single template page data.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"page_size\": 15,
    \"sort_by\": \"title\",
    \"sort_order\": \"asc\",
    \"search\": \"John\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'page_size' => 15,
            'sort_by' => 'title',
            'sort_order' => 'asc',
            'search' => 'John',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "page_size": 15,
    "sort_by": "title",
    "sort_order": "asc",
    "search": "John"
};

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

Request      

GET api/v1/companies/{company_uuid}/custom-settings

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Query Parameters

page   integer  optional  

optional The page number. Example: 1

Body Parameters

page_size   integer  optional  

optional The number of records you want per page. Example: 15

sort_by   string  optional  

optional The column name. Example: title

sort_order   string  optional  

optional The order in which you want your records. Example: asc

search   string  optional  

optional The general search, it will find matching string. Example: John

Show

requires authentication

Show detail of a company location setting

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings/908c1059-c320-301a-9190-0cafaa97cff6" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings/908c1059-c320-301a-9190-0cafaa97cff6';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings/908c1059-c320-301a-9190-0cafaa97cff6"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/custom-settings/{companyLocationCustomSetting_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyLocationCustomSetting_uuid   string   

Example: 908c1059-c320-301a-9190-0cafaa97cff6

companyUuid   string  optional  

Uuid of Company. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

companyLocationCustomSettingUuid   string  optional  

Uuid of CompanyLocationCustomSetting. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Create

requires authentication

Create a company location custom setting

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Services\",
    \"value\": \"Pest control\",
    \"company_location_uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Services',
            'value' => 'Pest control',
            'company_location_uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings"
);

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

let body = {
    "name": "Services",
    "value": "Pest control",
    "company_location_uuid": "3245d630-24fd-11ec-accd-e397aec85c7f"
};

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

Request      

POST api/v1/companies/{company_uuid}/custom-settings

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyUuid   string  optional  

Uuid of Company. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

name   string   

The name of custom setting. Example: Services

value   string   

The value of custom setting. Example: Pest control

company_location_uuid   string  optional  

option The specific company location uuid of the custom setting. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Update

requires authentication

Update a company location custom setting

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings/4befa921-2e42-3eae-8eb2-ce0d20d23046" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Services\",
    \"value\": \"Pest control\",
    \"company_location_uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings/4befa921-2e42-3eae-8eb2-ce0d20d23046';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Services',
            'value' => 'Pest control',
            'company_location_uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings/4befa921-2e42-3eae-8eb2-ce0d20d23046"
);

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

let body = {
    "name": "Services",
    "value": "Pest control",
    "company_location_uuid": "3245d630-24fd-11ec-accd-e397aec85c7f"
};

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

Request      

PUT api/v1/companies/{company_uuid}/custom-settings/{companyLocationCustomSetting_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyLocationCustomSetting_uuid   string   

Example: 4befa921-2e42-3eae-8eb2-ce0d20d23046

companyUuid   string  optional  

Uuid of Company. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

companyLocationCustomSettingUuid   string  optional  

Uuid of CompanyLocationCustomSetting. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

name   string   

The name of custom setting. Example: Services

value   string   

The value of custom setting. Example: Pest control

company_location_uuid   string  optional  

option The specific company location uuid of the custom setting. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Delete

requires authentication

Deletes a company location custom setting

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings/45569bfb-2ad6-3d47-9b35-0a171c306cb9" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings/45569bfb-2ad6-3d47-9b35-0a171c306cb9';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/custom-settings/45569bfb-2ad6-3d47-9b35-0a171c306cb9"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/custom-settings/{companyLocationCustomSetting_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

companyLocationCustomSetting_uuid   string   

Example: 45569bfb-2ad6-3d47-9b35-0a171c306cb9

companyUuid   string  optional  

Uuid of Company. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

companyLocationCustomSettingUuid   string  optional  

Uuid of CompanyLocationCustomSetting. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Import Type

API for Import Type

List

requires authentication

Shows the list of tags with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/import-types" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/import-types';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/import-types"
);

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

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

Request      

GET api/v1/import-types

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 19

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 13

sort_by   string  optional  

The column name. Example : name Example: animi

sort_order   string  optional  

The order in which you want your records. Example : asc Example: perferendis

search   string  optional  

The general search, it will find matching string. Example : "Categories" Example: dicta

name   string  optional  

The name of import type. Example : "Categories" Example: sed

code   string  optional  

The code of import type. Example : "categories" Example: et

Proposal

API for Proposal

Get

requires authentication

Display the selected proposal.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/preview" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/preview';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/preview"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/preview

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

Get client IP Address and Date time prior to accepting the proposal

requires authentication

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/get-ip-datetime" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/get-ip-datetime';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/get-ip-datetime"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/get-ip-datetime

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

Store Proposal Inquiry

requires authentication

Send inquiry request from users

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/support-request" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"support_type\": \"\'General Inquiry\'\",
    \"screenshots_url\": [
        \"https:\\/\\/example.net\\/image1.jpg\",
        \"https:\\/\\/example.net\\/image1.png\"
    ],
    \"description\": \"\'I cannot access documents. Please help.\'\",
    \"no_attachments\": false
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/support-request';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'support_type' => '\'General Inquiry\'',
            'screenshots_url' => [
                'https://example.net/image1.jpg',
                'https://example.net/image1.png',
            ],
            'description' => '\'I cannot access documents. Please help.\'',
            'no_attachments' => false,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/support-request"
);

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

let body = {
    "support_type": "'General Inquiry'",
    "screenshots_url": [
        "https:\/\/example.net\/image1.jpg",
        "https:\/\/example.net\/image1.png"
    ],
    "description": "'I cannot access documents. Please help.'",
    "no_attachments": false
};

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

Request      

POST api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/support-request

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

Body Parameters

support_type   string   

The support type. Example: 'General Inquiry'

client_detail   object  optional  
screenshots_url   string[]   

The screenshots URL string.

description   string   

The support request details. Example: 'I cannot access documents. Please help.'

no_attachments   boolean   

Check if request has attachments. Example: false

Upload

requires authentication

Upload photos for Cover Letter or Photo Layout pages

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/4fbc1e7b-c6f0-3254-94ce-260bb08be7fe/support-request-upload" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"screenshot_url\": \"https:\\/\\/example.net\\/test.png\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/4fbc1e7b-c6f0-3254-94ce-260bb08be7fe/support-request-upload';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'screenshot_url' => 'https://example.net/test.png',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/4fbc1e7b-c6f0-3254-94ce-260bb08be7fe/support-request-upload"
);

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

let body = {
    "screenshot_url": "https:\/\/example.net\/test.png"
};

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

Request      

POST api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/{supportRequestUuid}/support-request-upload

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

supportRequestUuid   string   

Example: 4fbc1e7b-c6f0-3254-94ce-260bb08be7fe

Body Parameters

screenshot_url   string   

The url of the attached image. Example: https://example.net/test.png

Accept and Sign

requires authentication

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/accept-sign" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"signature_photo_url\": \"http:\\/\\/kling.com\\/\",
    \"proposal_pdf_url\": \"http:\\/\\/emard.com\\/qui-sequi-quisquam-totam-libero.html\",
    \"auth_code\": \"aut\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/accept-sign';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'signature_photo_url' => 'http://kling.com/',
            'proposal_pdf_url' => 'http://emard.com/qui-sequi-quisquam-totam-libero.html',
            'auth_code' => 'aut',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/accept-sign"
);

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

let body = {
    "signature_photo_url": "http:\/\/kling.com\/",
    "proposal_pdf_url": "http:\/\/emard.com\/qui-sequi-quisquam-totam-libero.html",
    "auth_code": "aut"
};

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

Request      

POST api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/accept-sign

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

Body Parameters

accepted_confirmation_uuids   object  optional  
signature_photo_url   string   

The image url. Example: http://kling.com/

proposal_pdf_url   string   

The pdf file url. Example: http://emard.com/qui-sequi-quisquam-totam-libero.html

auth_code   string  optional  

Example: aut

Replicate Signature

requires authentication

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/replace-signature" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"signature_photo_url\": \"http:\\/\\/christiansen.info\\/laborum-laborum-autem-nisi-nulla-odit-blanditiis\",
    \"proposal_pdf_url\": \"http:\\/\\/boyle.com\\/necessitatibus-hic-magni-autem-eum-perferendis-quisquam-ut-facilis\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/replace-signature';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'signature_photo_url' => 'http://christiansen.info/laborum-laborum-autem-nisi-nulla-odit-blanditiis',
            'proposal_pdf_url' => 'http://boyle.com/necessitatibus-hic-magni-autem-eum-perferendis-quisquam-ut-facilis',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/replace-signature"
);

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

let body = {
    "signature_photo_url": "http:\/\/christiansen.info\/laborum-laborum-autem-nisi-nulla-odit-blanditiis",
    "proposal_pdf_url": "http:\/\/boyle.com\/necessitatibus-hic-magni-autem-eum-perferendis-quisquam-ut-facilis"
};

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

Request      

POST api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/replace-signature

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

Body Parameters

signature_photo_url   string   

The image url. Example: http://christiansen.info/laborum-laborum-autem-nisi-nulla-odit-blanditiis

proposal_pdf_url   string   

The pdf file url. Example: http://boyle.com/necessitatibus-hic-magni-autem-eum-perferendis-quisquam-ut-facilis

Update Attached Document

requires authentication

Patch the specified proposal.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/update-attachment" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "documentIndex=10475068.530055"\
    --form "documentFile=@/tmp/phpVdav5O" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/update-attachment';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'documentIndex',
                'contents' => '10475068.530055'
            ],
            [
                'name' => 'documentFile',
                'contents' => fopen('/tmp/phpVdav5O', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/update-attachment"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('documentIndex', '10475068.530055');
body.append('documentFile', document.querySelector('input[name="documentFile"]').files[0]);

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

Request      

POST api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/update-attachment

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

Body Parameters

documentFile   file  optional  

The updated document file. Example : WDIIR.pdf Example: /tmp/phpVdav5O

documentIndex   number  optional  

The document index number. Example : 1 Example: 10475068.530055

Log Video Clicked

requires authentication

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/video-clicked" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"video_type\": \"et\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/video-clicked';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'video_type' => 'et',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/video-clicked"
);

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

let body = {
    "video_type": "et"
};

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

Request      

POST api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/video-clicked

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

Body Parameters

video_type   'service'  optional  

| 'screen_recording' Example: et

Decline

requires authentication

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/decline" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/decline';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/decline"
);

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

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

Request      

PATCH api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/decline

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

Update Selected Pricing

requires authentication

Patch the specified proposal.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/update-selected-pricing" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"proposal_values\": []
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/update-selected-pricing';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'proposal_values' => [],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/update-selected-pricing"
);

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

let body = {
    "proposal_values": []
};

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

Request      

PATCH api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/update-selected-pricing

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

Body Parameters

proposal_values   object  optional  

The collected data of the proposal in object format. Example : {"price":1000.00,"currency":"$"}

Submit Customer Forms

requires authentication

Patch the specified proposal.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/customer-forms" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"formValues\": [],
    \"submittedForms\": [],
    \"proposal_values\": []
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/customer-forms';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'formValues' => [],
            'submittedForms' => [],
            'proposal_values' => [],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/proposals/15/customer-forms"
);

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

let body = {
    "formValues": [],
    "submittedForms": [],
    "proposal_values": []
};

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

Request      

PATCH api/v1/companies/{company_uuid}/proposals/{proposal_uuid}/customer-forms

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

proposal_uuid   integer   

Example: 15

Body Parameters

formValues   object   
attachedDocuments   object  optional  
submittedForms   object   
proposal_values   object  optional  

The collected data of the proposal in object format. Example : {"price":1000.00,"currency":"$"}

List

requires authentication

Shows the list of proposal with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/proposals" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"ignore_cached\": false,
    \"date_range_start\": \"2025-09-08T14:09:08\",
    \"date_range_end\": \"2040-01-15\",
    \"timezone\": \"Asia\\/Seoul\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'ignore_cached' => false,
            'date_range_start' => '2025-09-08T14:09:08',
            'date_range_end' => '2040-01-15',
            'timezone' => 'Asia/Seoul',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals"
);

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

let body = {
    "ignore_cached": false,
    "date_range_start": "2025-09-08T14:09:08",
    "date_range_end": "2040-01-15",
    "timezone": "Asia\/Seoul"
};

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

Request      

GET api/v1/proposals

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 17

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 5

sort_by   string  optional  

The column name. Example : name Example: est

sort_order   string  optional  

The order in which you want your records. Example : asc Example: repellendus

search   string  optional  

The general search, it will find matching string. Example : home Example: consequuntur

search_by   string  optional  

The specific field to search within. Options: customer_name, title, description. Example : customer_name Example: enim

company_location_uuid   string  optional  

The UUID of company location. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 4467975f-903d-318a-b20d-3d4b7551195a

company_location_uuids   string  optional  

string[] The UUID of company location. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: est

status_uuid   string  optional  

string[] The UUID of proposal status. Example : ["815d3d9c-f371-3781-8456-7e6954b5b0f5"] Example: dbc7529c-801a-3754-a6de-1ff2c4a2b6e7

customer_uuid   string  optional  

The UUID of a customer. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 016e8a2f-66a1-3224-82a7-08077af4a0e2

include_fields   string  optional  

string[] Optionally include related data for the proposal. Example : "company" Example: ipsum

user_uuid   string  optional  

Filter by the user that created proposals. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: fd783183-7df4-301d-9036-cfad05415a3a

timezone   string  optional  

Optional timezone for date filtering. Falls back to user's favorite location timezone, then MST. Example : "America/New_York" Example: Africa/Luanda

date_range_start   string  optional  

Start date for filtering proposals. Example : "2024-08-01" Example: nihil

date_range_end   string  optional  

End date for filtering proposals. Example : "2024-08-13" Example: esse

date_range_type   string  optional  

Type of date to filter by. Options: created_at, updated_at. Example : "created_at" Example: soluta

Body Parameters

include_fields   string[]  optional  
ignore_cached   boolean  optional  

Example: false

date_range_start   string  optional  

Must be a valid date. Example: 2025-09-08T14:09:08

date_range_end   string  optional  

Must be a valid date. Must be a date after or equal to date_range_start. Example: 2040-01-15

timezone   string  optional  

Must be a valid time zone, such as Africa/Accra. Example: Asia/Seoul

Export List

requires authentication

Returns a CSV file of list of filtered proposal list.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/proposals/export-list" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/export-list';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/export-list"
);

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

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

Request      

GET api/v1/proposals/export-list

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 19

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 6

sort_by   string  optional  

The column name. Example : name Example: sequi

sort_order   string  optional  

The order in which you want your records. Example : asc Example: et

search   string  optional  

The general search, it will find matching string. Example : home Example: maiores

company_location_uuid   string  optional  

The UUID of company location. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 9f65e157-93bf-315f-b5db-04ce1fc8b984

company_location_uuids   string  optional  

string[] The UUID of company location. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: a

status_uuid   string  optional  

The UUID of proposal status. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 139ada89-6b11-33f8-b1fa-38ac3c7f8985

customer_uuid   string  optional  

The UUID of a customer. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: d18dead5-4f25-3b7c-ba4b-27bb3aec35b5

include_fields   string  optional  

string[] Optionally include related data for the proposal. Example : "company" Example: repellat

user_uuid   string  optional  

Filter by the user that created proposals. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: fa02ca0f-b8b6-3eae-93cf-52121c0771ba

Summary

requires authentication

Shows the summary of proposal. Returns number of items per Proposal status.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/proposals/summary" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/summary';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/summary"
);

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

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

Request      

GET api/v1/proposals/summary

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Get

requires authentication

Display the selected proposal.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/proposals/15" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15"
);

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

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

Request      

GET api/v1/proposals/{proposal_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

List of Activity Logs

requires authentication

Shows the list of proposal's activity logs with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs"
);

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

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

Request      

GET api/v1/proposals/{proposal_uuid}/activity-logs

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

page   integer  optional  

The page number. Example : 1 Example: 5

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 10

sort_by   string  optional  

The column name. Example : name Example: eos

sort_order   string  optional  

The order in which you want your records. Example : asc Example: quisquam

search   string  optional  

The general search, it will find matching string. Example : home Example: voluptatem

Body Parameters

include_fields   object  optional  

Get the events associated with a specific proposal activity

requires authentication

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity/0a4836de-c38d-33c7-b3e4-c04187f076eb/events" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity/0a4836de-c38d-33c7-b3e4-c04187f076eb/events';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity/0a4836de-c38d-33c7-b3e4-c04187f076eb/events"
);

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

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

Request      

GET api/v1/proposals/{proposal_uuid}/activity/{activity_uuid}/events

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

activity_uuid   string   

Example: 0a4836de-c38d-33c7-b3e4-c04187f076eb

Download TARF XML

requires authentication

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/proposals/15/tarf-xml-url" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15/tarf-xml-url';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/tarf-xml-url"
);

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

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

Request      

GET api/v1/proposals/{proposal_uuid}/tarf-xml-url

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

Download California WDO XML

requires authentication

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/proposals/15/cali-wdo-report-url" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15/cali-wdo-report-url';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/cali-wdo-report-url"
);

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

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

Request      

GET api/v1/proposals/{proposal_uuid}/cali-wdo-report-url

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

Create

requires authentication

Store a newly created proposal activity entry

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"description\": \"Be sure to follow-up with the customer.\'\",
    \"remind_at\": \"07\\/23\\/2024\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'description' => 'Be sure to follow-up with the customer.\'',
            'remind_at' => '07/23/2024',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs"
);

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

let body = {
    "description": "Be sure to follow-up with the customer.'",
    "remind_at": "07\/23\/2024"
};

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

Request      

POST api/v1/proposals/{proposal_uuid}/activity-logs

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

Body Parameters

description   string   

The description of activity entry. Example: Be sure to follow-up with the customer.'

remind_at   string   

The date of reminder through email. Example: 07/23/2024

action

requires authentication

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs/f691106d-26a2-34a9-bb3a-a9aaaad71fbe/ipsum" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs/f691106d-26a2-34a9-bb3a-a9aaaad71fbe/ipsum';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs/f691106d-26a2-34a9-bb3a-a9aaaad71fbe/ipsum"
);

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

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

Request      

POST api/v1/proposals/{proposal_uuid}/activity-logs/{activityEntryUuid}/{action}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

activityEntryUuid   string   

Example: f691106d-26a2-34a9-bb3a-a9aaaad71fbe

action   string   

Example: ipsum

Create

requires authentication

Store a newly created proposal.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/proposals" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"dolores\",
    \"description\": \"Sit error ut sapiente consequatur similique quisquam et.\",
    \"company_location_uuid\": \"85253619-84a4-39f4-95cc-fef45c2faf4f\",
    \"customer_uuid\": \"223528bf-0f74-3bb2-beb7-7eb741524e53\",
    \"customer_address_uuid\": \"36c7f922-82eb-3f23-9192-72fde35bb4f0\",
    \"status_uuid\": \"ac73a48a-8aa0-3671-abf3-23396b5fe36e\",
    \"service_plan_uuids\": [
        \"dolorem\"
    ],
    \"proposal_values\": [],
    \"proposal_template_uuid\": \"298d62f8-59a3-3640-b19b-0e530ca922ea\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => 'dolores',
            'description' => 'Sit error ut sapiente consequatur similique quisquam et.',
            'company_location_uuid' => '85253619-84a4-39f4-95cc-fef45c2faf4f',
            'customer_uuid' => '223528bf-0f74-3bb2-beb7-7eb741524e53',
            'customer_address_uuid' => '36c7f922-82eb-3f23-9192-72fde35bb4f0',
            'status_uuid' => 'ac73a48a-8aa0-3671-abf3-23396b5fe36e',
            'service_plan_uuids' => [
                'dolorem',
            ],
            'proposal_values' => [],
            'proposal_template_uuid' => '298d62f8-59a3-3640-b19b-0e530ca922ea',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals"
);

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

let body = {
    "title": "dolores",
    "description": "Sit error ut sapiente consequatur similique quisquam et.",
    "company_location_uuid": "85253619-84a4-39f4-95cc-fef45c2faf4f",
    "customer_uuid": "223528bf-0f74-3bb2-beb7-7eb741524e53",
    "customer_address_uuid": "36c7f922-82eb-3f23-9192-72fde35bb4f0",
    "status_uuid": "ac73a48a-8aa0-3671-abf3-23396b5fe36e",
    "service_plan_uuids": [
        "dolorem"
    ],
    "proposal_values": [],
    "proposal_template_uuid": "298d62f8-59a3-3640-b19b-0e530ca922ea"
};

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

Request      

POST api/v1/proposals

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

title   string   

The title of the proposal. Example : Pest Route Initial Proposal Example: dolores

description   string  optional  

The paragraph describing the proposal. Example: Sit error ut sapiente consequatur similique quisquam et.

company_location_uuid   string   

The UUID of user's company location. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 85253619-84a4-39f4-95cc-fef45c2faf4f

customer_uuid   string   

The UUID of customer you wish to send the proposal. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 223528bf-0f74-3bb2-beb7-7eb741524e53

customer_address_uuid   string   

The UUID of customer's address. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 36c7f922-82eb-3f23-9192-72fde35bb4f0

status_uuid   string   

The UUID of proposal status. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: ac73a48a-8aa0-3671-abf3-23396b5fe36e

service_plan_uuids   string[]  optional  

The list of ServicePlan's UUID you want to add in the proposal. Example : ["815d3d9c-f371-3781-8456-7e6954b5b0f5", "815d3d9c-f371-3781-8456-7e6954b5b0f5"]

proposal_values   object  optional  

The collected data of the proposal in object format. Example : {"price":1000.00,"currency":"$"}

proposal_template_uuid   string   

The UUID of proposal template. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 298d62f8-59a3-3640-b19b-0e530ca922ea

Duplicate

requires authentication

This endpoint lets user to duplicate proposal and set into a draft mode

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/3245d630-24fd-11ec-accd-e397aec85c7f/duplicate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/3245d630-24fd-11ec-accd-e397aec85c7f/duplicate';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/3245d630-24fd-11ec-accd-e397aec85c7f/duplicate"
);

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

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

Request      

POST api/v1/proposals/{proposal_uuid}/duplicate

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   string  optional  

uuid required The uuid of the proposal. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Upload Review Photo

requires authentication

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/upload-review-photo" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "type='cover'."\
    --form "layout='Tiled'."\
    --form "photo=@/tmp/php8GqL9R" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15/upload-review-photo';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'type',
                'contents' => ''cover'.'
            ],
            [
                'name' => 'layout',
                'contents' => ''Tiled'.'
            ],
            [
                'name' => 'photo',
                'contents' => fopen('/tmp/php8GqL9R', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/upload-review-photo"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('type', ''cover'.');
body.append('layout', ''Tiled'.');
body.append('photo', document.querySelector('input[name="photo"]').files[0]);

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

Request      

POST api/v1/proposals/{proposal_uuid}/upload-review-photo

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

Body Parameters

photo   file   

The image file. Example: /tmp/php8GqL9R

type   enum  optional  

'cover' | 'photos' required The photo type. Example: 'cover'.

layout   enum  optional  

'Tiled' | 'Stacked' required The photo type. Example: 'Tiled'.

Resync document

requires authentication

Resync document the specified proposal.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/push-to-crm" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"hic\",
    \"description\": \"Amet voluptatum iure ex voluptas nesciunt esse.\",
    \"company_location_uuid\": \"f4cea6ce-a6ee-39cc-8c40-5622ab9f4b5f\",
    \"customer_uuid\": \"e29c47e9-11dd-37cd-919a-f9aa5d949893\",
    \"customer_address_uuid\": \"35a583fd-28e9-39e6-ad6a-1d18cbb04aec\",
    \"status_uuid\": \"fe021047-dcf3-3968-9eea-ecd9c76b84a0\",
    \"service_plan_uuids\": [
        \"qui\"
    ],
    \"proposal_values\": [],
    \"proposal_template_uuid\": \"2c8770b3-cbdf-3e8f-b443-6070647d5453\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15/push-to-crm';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => 'hic',
            'description' => 'Amet voluptatum iure ex voluptas nesciunt esse.',
            'company_location_uuid' => 'f4cea6ce-a6ee-39cc-8c40-5622ab9f4b5f',
            'customer_uuid' => 'e29c47e9-11dd-37cd-919a-f9aa5d949893',
            'customer_address_uuid' => '35a583fd-28e9-39e6-ad6a-1d18cbb04aec',
            'status_uuid' => 'fe021047-dcf3-3968-9eea-ecd9c76b84a0',
            'service_plan_uuids' => [
                'qui',
            ],
            'proposal_values' => [],
            'proposal_template_uuid' => '2c8770b3-cbdf-3e8f-b443-6070647d5453',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/push-to-crm"
);

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

let body = {
    "title": "hic",
    "description": "Amet voluptatum iure ex voluptas nesciunt esse.",
    "company_location_uuid": "f4cea6ce-a6ee-39cc-8c40-5622ab9f4b5f",
    "customer_uuid": "e29c47e9-11dd-37cd-919a-f9aa5d949893",
    "customer_address_uuid": "35a583fd-28e9-39e6-ad6a-1d18cbb04aec",
    "status_uuid": "fe021047-dcf3-3968-9eea-ecd9c76b84a0",
    "service_plan_uuids": [
        "qui"
    ],
    "proposal_values": [],
    "proposal_template_uuid": "2c8770b3-cbdf-3e8f-b443-6070647d5453"
};

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

Request      

POST api/v1/proposals/{proposal_uuid}/push-to-crm

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

Body Parameters

title   string  optional  

The title of the proposal. Example : Pest Route Initial Proposal Example: hic

description   string  optional  

The paragraph describing the proposal. Example: Amet voluptatum iure ex voluptas nesciunt esse.

company_location_uuid   string  optional  

The UUID of user's company location. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: f4cea6ce-a6ee-39cc-8c40-5622ab9f4b5f

customer_uuid   string  optional  

The UUID of customer you wish to send the proposal. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: e29c47e9-11dd-37cd-919a-f9aa5d949893

customer_address_uuid   string  optional  

The UUID of customer's address. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 35a583fd-28e9-39e6-ad6a-1d18cbb04aec

status_uuid   string  optional  

The UUID of proposal status. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: fe021047-dcf3-3968-9eea-ecd9c76b84a0

service_plan_uuids   string[]  optional  

The list of ServicePlan's UUID you want to add in the proposal. Example : ['815d3d9c-f371-3781-8456-7e6954b5b0f5', '815d3d9c-f371-3781-8456-7e6954b5b0f5']

proposal_values   object  optional  

The collected data of the proposal in object format. Example : {"price":1000.00,"currency":"$"}

proposal_template_uuid   string   

The UUID of proposal template. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 2c8770b3-cbdf-3e8f-b443-6070647d5453

Update

requires authentication

Updates the specified proposal.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"\\\"Pest Route Initial Proposal\\\"\",
    \"description\": \"\\\"Lorem, ipsum dolor sit amet consectetur adipisicing elit.\\\"\",
    \"company_location_uuid\": \"2437665e-19c6-3388-bd1f-3d262079d5df\",
    \"customer_uuid\": \"f23c40c2-437b-3268-9813-a93f864de779\",
    \"customer_address_uuid\": \"dc1cbd40-a88e-3702-9c8a-319ebfd57177\",
    \"status_uuid\": \"98f7cd7b-abe1-30a4-b630-1a601a052c8c\",
    \"service_plan_uuids\": [
        \"voluptas\"
    ],
    \"proposal_values\": [],
    \"proposal_template_uuid\": \"f84ee724-469d-37d7-adae-4c524b3cc314\",
    \"expire_at\": \"2025-09-08T14:09:08\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => '"Pest Route Initial Proposal"',
            'description' => '"Lorem, ipsum dolor sit amet consectetur adipisicing elit."',
            'company_location_uuid' => '2437665e-19c6-3388-bd1f-3d262079d5df',
            'customer_uuid' => 'f23c40c2-437b-3268-9813-a93f864de779',
            'customer_address_uuid' => 'dc1cbd40-a88e-3702-9c8a-319ebfd57177',
            'status_uuid' => '98f7cd7b-abe1-30a4-b630-1a601a052c8c',
            'service_plan_uuids' => [
                'voluptas',
            ],
            'proposal_values' => [],
            'proposal_template_uuid' => 'f84ee724-469d-37d7-adae-4c524b3cc314',
            'expire_at' => '2025-09-08T14:09:08',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15"
);

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

let body = {
    "title": "\"Pest Route Initial Proposal\"",
    "description": "\"Lorem, ipsum dolor sit amet consectetur adipisicing elit.\"",
    "company_location_uuid": "2437665e-19c6-3388-bd1f-3d262079d5df",
    "customer_uuid": "f23c40c2-437b-3268-9813-a93f864de779",
    "customer_address_uuid": "dc1cbd40-a88e-3702-9c8a-319ebfd57177",
    "status_uuid": "98f7cd7b-abe1-30a4-b630-1a601a052c8c",
    "service_plan_uuids": [
        "voluptas"
    ],
    "proposal_values": [],
    "proposal_template_uuid": "f84ee724-469d-37d7-adae-4c524b3cc314",
    "expire_at": "2025-09-08T14:09:08"
};

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

Request      

PUT api/v1/proposals/{proposal_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

Body Parameters

title   string   

The title of the proposal. Example: "Pest Route Initial Proposal"

description   string  optional  

The paragraph describing the proposal. Example: "Lorem, ipsum dolor sit amet consectetur adipisicing elit."

company_location_uuid   string   

The UUID of user's company location. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 2437665e-19c6-3388-bd1f-3d262079d5df

customer_uuid   string   

The UUID of customer you wish to send the proposal. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: f23c40c2-437b-3268-9813-a93f864de779

customer_address_uuid   string   

The UUID of customer's address. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: dc1cbd40-a88e-3702-9c8a-319ebfd57177

status_uuid   string   

The UUID of proposal status. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 98f7cd7b-abe1-30a4-b630-1a601a052c8c

service_plan_uuids   string[]  optional  

The list of ServicePlan's UUID you want to add in the proposal. Example : ['815d3d9c-f371-3781-8456-7e6954b5b0f5', '815d3d9c-f371-3781-8456-7e6954b5b0f5']

proposal_values   object  optional  

The collected data of the proposal in object format. Example : {"price":1000.00,"currency":"$"}

settings   object  optional  
proposal_template_uuid   string   

The UUID of proposal template. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: f84ee724-469d-37d7-adae-4c524b3cc314

include_fields   object  optional  
expire_at   string  optional  

Must be a valid date. Example: 2025-09-08T14:09:08

Update

requires authentication

Update a proposal activity entry

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs/827f871c-6faa-38e9-893c-df9aa85ab4a4" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"description\": \"Be sure to follow-up with the customer.\'\",
    \"remind_at\": \"07\\/23\\/2024\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs/827f871c-6faa-38e9-893c-df9aa85ab4a4';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'description' => 'Be sure to follow-up with the customer.\'',
            'remind_at' => '07/23/2024',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs/827f871c-6faa-38e9-893c-df9aa85ab4a4"
);

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

let body = {
    "description": "Be sure to follow-up with the customer.'",
    "remind_at": "07\/23\/2024"
};

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

Request      

PUT api/v1/proposals/{proposal_uuid}/activity-logs/{activityEntryUuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

activityEntryUuid   string   

Example: 827f871c-6faa-38e9-893c-df9aa85ab4a4

Body Parameters

description   string   

The description of activity entry. Example: Be sure to follow-up with the customer.'

remind_at   string   

The date of reminder through email. Example: 07/23/2024

Patch

requires authentication

Patch the specified proposal.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"rem\",
    \"description\": \"Qui eos veritatis rerum dolore et nisi.\",
    \"company_location_uuid\": \"6e766031-39e8-39e2-b59b-e4673c54fd21\",
    \"customer_uuid\": \"ae8a0079-ebbe-3eae-a13f-62e8fdf07796\",
    \"customer_address_uuid\": \"d641da53-676e-3d62-8a5b-fd077becfa7b\",
    \"status_uuid\": \"9e43241b-81a1-39a9-b05f-261cacb1e156\",
    \"service_plan_uuids\": [
        \"error\"
    ],
    \"proposal_values\": [],
    \"proposal_template_uuid\": \"55c1aa38-c166-3aea-a781-7e80aebd4445\",
    \"expire_at\": \"2025-09-08T14:09:08\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => 'rem',
            'description' => 'Qui eos veritatis rerum dolore et nisi.',
            'company_location_uuid' => '6e766031-39e8-39e2-b59b-e4673c54fd21',
            'customer_uuid' => 'ae8a0079-ebbe-3eae-a13f-62e8fdf07796',
            'customer_address_uuid' => 'd641da53-676e-3d62-8a5b-fd077becfa7b',
            'status_uuid' => '9e43241b-81a1-39a9-b05f-261cacb1e156',
            'service_plan_uuids' => [
                'error',
            ],
            'proposal_values' => [],
            'proposal_template_uuid' => '55c1aa38-c166-3aea-a781-7e80aebd4445',
            'expire_at' => '2025-09-08T14:09:08',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15"
);

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

let body = {
    "title": "rem",
    "description": "Qui eos veritatis rerum dolore et nisi.",
    "company_location_uuid": "6e766031-39e8-39e2-b59b-e4673c54fd21",
    "customer_uuid": "ae8a0079-ebbe-3eae-a13f-62e8fdf07796",
    "customer_address_uuid": "d641da53-676e-3d62-8a5b-fd077becfa7b",
    "status_uuid": "9e43241b-81a1-39a9-b05f-261cacb1e156",
    "service_plan_uuids": [
        "error"
    ],
    "proposal_values": [],
    "proposal_template_uuid": "55c1aa38-c166-3aea-a781-7e80aebd4445",
    "expire_at": "2025-09-08T14:09:08"
};

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

Request      

PATCH api/v1/proposals/{proposal_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

Body Parameters

title   string  optional  

The title of the proposal. Example : Pest Route Initial Proposal Example: rem

description   string  optional  

The paragraph describing the proposal. Example: Qui eos veritatis rerum dolore et nisi.

company_location_uuid   string  optional  

The UUID of user's company location. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 6e766031-39e8-39e2-b59b-e4673c54fd21

customer_uuid   string  optional  

The UUID of customer you wish to send the proposal. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: ae8a0079-ebbe-3eae-a13f-62e8fdf07796

customer_address_uuid   string  optional  

The UUID of customer's address. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: d641da53-676e-3d62-8a5b-fd077becfa7b

status_uuid   string  optional  

The UUID of proposal status. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 9e43241b-81a1-39a9-b05f-261cacb1e156

service_plan_uuids   string[]  optional  

The list of ServicePlan's UUID you want to add in the proposal. Example : ['815d3d9c-f371-3781-8456-7e6954b5b0f5', '815d3d9c-f371-3781-8456-7e6954b5b0f5']

proposal_values   object  optional  

The collected data of the proposal in object format. Example : {"price":1000.00,"currency":"$"}

settings   object  optional  
proposal_template_uuid   string   

The UUID of proposal template. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 55c1aa38-c166-3aea-a781-7e80aebd4445

include_fields   object  optional  
expire_at   string  optional  

Must be a valid date. Example: 2025-09-08T14:09:08

Share

requires authentication

Send proposal via email

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/share" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"recipients\": [
        \"johnsmith@example.net\",
        \"anasmith@example.net\"
    ],
    \"subject\": \"\\\"Pest Route Initial Proposal\\\"\",
    \"body\": \"\\\"Pest Route Initial Proposal\\\"\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15/share';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'recipients' => [
                'johnsmith@example.net',
                'anasmith@example.net',
            ],
            'subject' => '"Pest Route Initial Proposal"',
            'body' => '"Pest Route Initial Proposal"',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/share"
);

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

let body = {
    "recipients": [
        "johnsmith@example.net",
        "anasmith@example.net"
    ],
    "subject": "\"Pest Route Initial Proposal\"",
    "body": "\"Pest Route Initial Proposal\""
};

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

Request      

PATCH api/v1/proposals/{proposal_uuid}/share

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

Body Parameters

recipients   string[]   

The recipients of the proposal.

subject   string   

The subject of the proposal. Example: "Pest Route Initial Proposal"

body   string   

The body of the proposal. Example: "Pest Route Initial Proposal"

Delete

requires authentication

Delete a specified proposal.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15"
);

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

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

Request      

DELETE api/v1/proposals/{proposal_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

Delete Review Photo

requires authentication

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/delete-review-photo" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"image_url\": \"https:\\/\\/shanahan.info\\/sit-occaecati-dolores-quia-enim-dolore-dolorem-velit.html\",
    \"type\": \"\'cover\'.\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15/delete-review-photo';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'image_url' => 'https://shanahan.info/sit-occaecati-dolores-quia-enim-dolore-dolorem-velit.html',
            'type' => '\'cover\'.',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/delete-review-photo"
);

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

let body = {
    "image_url": "https:\/\/shanahan.info\/sit-occaecati-dolores-quia-enim-dolore-dolorem-velit.html",
    "type": "'cover'."
};

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

Request      

DELETE api/v1/proposals/{proposal_uuid}/delete-review-photo

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

Body Parameters

image_url   string   

The image url. Example: https://shanahan.info/sit-occaecati-dolores-quia-enim-dolore-dolorem-velit.html

type   enum  optional  

'cover' | 'photos' required The photo type. Example: 'cover'.

Delete

requires authentication

Delete a proposal activity entry

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs/bb71d17b-66e2-3ec4-bc53-fdcf89e09201" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs/bb71d17b-66e2-3ec4-bc53-fdcf89e09201';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/proposals/15/activity-logs/bb71d17b-66e2-3ec4-bc53-fdcf89e09201"
);

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

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

Request      

DELETE api/v1/proposals/{proposal_uuid}/activity-logs/{activityEntryUuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

proposal_uuid   integer   

Example: 15

activityEntryUuid   string   

Example: bb71d17b-66e2-3ec4-bc53-fdcf89e09201

Service Agreement

API for service agreement details

List

requires authentication

Shows the list of company service agreements with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/service-agreements

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 13

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 12

sort_by   string  optional  

The column name. Example : title Example: cum

sort_order   string  optional  

The order in which you want your records. Example : asc Example: sapiente

search   string  optional  

The general search, it will find matching string. Example : home Example: deleniti

filter_by_uuids   string  optional  

string[] To fitler by selected uuids. Example : [uuid, uuid-2] Example: aut

Show

requires authentication

Show a single service agreement.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/service-agreements/{serviceAgreement_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

serviceAgreement_uuid   integer   

Example: 1

Store

requires authentication

Store a service agreement.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"vitae\",
    \"content\": \"sapiente\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => 'vitae',
            'content' => 'sapiente',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements"
);

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

let body = {
    "title": "vitae",
    "content": "sapiente"
};

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

Request      

POST api/v1/companies/{company_uuid}/service-agreements

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

title   string   

The title of the service agreement. Example : Termites Service Agreement Example: vitae

content   string   

The content of the service agreement. Example : Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor Example: sapiente

Update

requires authentication

Update a service agreement.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"veritatis\",
    \"content\": \"quod\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => 'veritatis',
            'content' => 'quod',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1"
);

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

let body = {
    "title": "veritatis",
    "content": "quod"
};

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

Request      

PUT api/v1/companies/{company_uuid}/service-agreements/{serviceAgreement_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

serviceAgreement_uuid   integer   

Example: 1

Body Parameters

title   string   

The title of the service agreement. Example : Termites Service Agreement Example: veritatis

content   string   

The content of the service agreement. Example : Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor Example: quod

Patch

requires authentication

Patch a service agreement.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"neque\",
    \"content\": \"cupiditate\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => 'neque',
            'content' => 'cupiditate',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1"
);

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

let body = {
    "title": "neque",
    "content": "cupiditate"
};

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

Request      

PATCH api/v1/companies/{company_uuid}/service-agreements/{serviceAgreement_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

serviceAgreement_uuid   integer   

Example: 1

Body Parameters

title   string  optional  

optional The title of the service agreement. Example : Termites Service Agreement Example: neque

content   string  optional  

optional The content of the service agreement. Example : Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor Example: cupiditate

Patch - Set as Active

requires authentication

Set as Active a service agreement version.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1/setAsActive" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"title\": \"omnis\",
    \"content\": \"non\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1/setAsActive';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'title' => 'omnis',
            'content' => 'non',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1/setAsActive"
);

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

let body = {
    "title": "omnis",
    "content": "non"
};

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

Request      

PATCH api/v1/companies/{company_uuid}/service-agreements/{serviceAgreement_uuid}/setAsActive

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

serviceAgreement_uuid   integer   

Example: 1

Body Parameters

title   string  optional  

optional The title of the service agreement. Example : Termites Service Agreement Example: omnis

content   string  optional  

optional The content of the service agreement. Example : Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor Example: non

Delete

requires authentication

Delete a service agreement.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/service-agreements/1"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/service-agreements/{serviceAgreement_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

serviceAgreement_uuid   integer   

Example: 1

Company

API for company details

PATCH api/v1/companies/{company_uuid}/update-limit/{entity}

requires authentication

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/update-limit/et" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/update-limit/et';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/update-limit/et"
);

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

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

Request      

PATCH api/v1/companies/{company_uuid}/update-limit/{entity}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

entity   string   

Example: et

List / Fetch.

requires authentication

Shows the list of company or fetch single record using uuid.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1"
);

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

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

Request      

GET api/v1/companies/{company_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

uuid   string  optional  

optional The company uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Store company logo.

requires authentication

This endpoint lets company to upload or update their logo.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/image" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "image_url=@/tmp/php0bnw3P" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/image';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'image_url',
                'contents' => fopen('/tmp/php0bnw3P', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/image"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('image_url', document.querySelector('input[name="image_url"]').files[0]);

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

Request      

POST api/v1/companies/{company_uuid}/image

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

uuid   string   

The company uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

image_url   file   

The image file. Example: /tmp/php0bnw3P

Update Company

requires authentication

This endpoint lets user to update a company.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Smarter Launch\",
    \"phone\": \"5554448888\",
    \"email\": \"hello@smarterlaunch.com\",
    \"address1\": \"\'123 Smarter Launch Way\'\",
    \"address2\": \"\'Suite 101\'\",
    \"city\": \"Queen Creek\",
    \"country_state_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"country_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"postal_code\": \"85410\",
    \"latitude\": \"23.0396\",
    \"longitude\": \"72.566\",
    \"primary_color\": \"#009CFF\",
    \"secondary_color\": \"#FFFFFF\",
    \"settings\": [],
    \"image_url\": \"http:\\/\\/koepp.info\\/\",
    \"company_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"description\": \"We are helping take your business to the next level. Hop in!\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Smarter Launch',
            'phone' => '5554448888',
            'email' => 'hello@smarterlaunch.com',
            'address1' => '\'123 Smarter Launch Way\'',
            'address2' => '\'Suite 101\'',
            'city' => 'Queen Creek',
            'country_state_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'country_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'postal_code' => '85410',
            'latitude' => '23.0396',
            'longitude' => '72.566',
            'primary_color' => '#009CFF',
            'secondary_color' => '#FFFFFF',
            'settings' => [],
            'image_url' => 'http://koepp.info/',
            'company_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'description' => 'We are helping take your business to the next level. Hop in!',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1"
);

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

let body = {
    "name": "Smarter Launch",
    "phone": "5554448888",
    "email": "hello@smarterlaunch.com",
    "address1": "'123 Smarter Launch Way'",
    "address2": "'Suite 101'",
    "city": "Queen Creek",
    "country_state_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "country_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "postal_code": "85410",
    "latitude": "23.0396",
    "longitude": "72.566",
    "primary_color": "#009CFF",
    "secondary_color": "#FFFFFF",
    "settings": [],
    "image_url": "http:\/\/koepp.info\/",
    "company_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "description": "We are helping take your business to the next level. Hop in!"
};

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

Request      

PUT api/v1/companies/{company_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the company. Example: Smarter Launch

phone   string   

The last name of the company. Example: 5554448888

email   string   

The email of the company. Example: hello@smarterlaunch.com

address1   string   

The address of the company. Example: '123 Smarter Launch Way'

address2   string  optional  

optional The address of the company. Example: 'Suite 101'

city   string   

The company city name. Example: Queen Creek

country_state_uuid   string   

The company state uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

country_uuid   string   

The company country uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

postal_code   string  optional  

optional The postal code of the company. Example: 85410

latitude   string  optional  

optional The latitude of the company. Example: 23.0396

longitude   string  optional  

optional The longitude of the company. Example: 72.566

primary_color   string  optional  

optional The primary color. Example: #009CFF

secondary_color   string  optional  

optional The secondary color. Example: #FFFFFF

custom_settings   object  optional  
settings   object  optional  
available_integration_uuids   object  optional  
image_url   string  optional  

Example: http://koepp.info/

company_uuid   string  optional  

optional The uuid of the company. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

description   string  optional  

optional The company description. Example: We are helping take your business to the next level. Hop in!

Patch Company

requires authentication

This endpoint lets user to update a company.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Smarter Launch\",
    \"phone\": \"5554448888\",
    \"email\": \"hello@smarterlaunch.com\",
    \"address1\": \"\'123 Smarter Launch Way\'\",
    \"address2\": \"\'Suite 101\'\",
    \"city\": \"Queen Creek\",
    \"country_state_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"country_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"postal_code\": \"85410\",
    \"latitude\": \"23.0396\",
    \"longitude\": \"72.566\",
    \"primary_color\": \"#009CFF\",
    \"secondary_color\": \"#FFFFFF\",
    \"settings\": [],
    \"website_url\": \"http:\\/\\/nitzsche.com\\/\",
    \"google_my_business_listing\": \"https:\\/\\/wuckert.biz\\/et-tempore-delectus-cupiditate-sed-sed-eos-est.html\",
    \"image_url\": \"http:\\/\\/balistreri.com\\/sapiente-qui-qui-eveniet-enim-recusandae\",
    \"company_uuid\": \"ecd24580-2749-11ec-9b86-1102c06e74b4\",
    \"description\": \"We are helping take your business to the next level. Hop in!\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Smarter Launch',
            'phone' => '5554448888',
            'email' => 'hello@smarterlaunch.com',
            'address1' => '\'123 Smarter Launch Way\'',
            'address2' => '\'Suite 101\'',
            'city' => 'Queen Creek',
            'country_state_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'country_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'postal_code' => '85410',
            'latitude' => '23.0396',
            'longitude' => '72.566',
            'primary_color' => '#009CFF',
            'secondary_color' => '#FFFFFF',
            'settings' => [],
            'website_url' => 'http://nitzsche.com/',
            'google_my_business_listing' => 'https://wuckert.biz/et-tempore-delectus-cupiditate-sed-sed-eos-est.html',
            'image_url' => 'http://balistreri.com/sapiente-qui-qui-eveniet-enim-recusandae',
            'company_uuid' => 'ecd24580-2749-11ec-9b86-1102c06e74b4',
            'description' => 'We are helping take your business to the next level. Hop in!',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1"
);

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

let body = {
    "name": "Smarter Launch",
    "phone": "5554448888",
    "email": "hello@smarterlaunch.com",
    "address1": "'123 Smarter Launch Way'",
    "address2": "'Suite 101'",
    "city": "Queen Creek",
    "country_state_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "country_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "postal_code": "85410",
    "latitude": "23.0396",
    "longitude": "72.566",
    "primary_color": "#009CFF",
    "secondary_color": "#FFFFFF",
    "settings": [],
    "website_url": "http:\/\/nitzsche.com\/",
    "google_my_business_listing": "https:\/\/wuckert.biz\/et-tempore-delectus-cupiditate-sed-sed-eos-est.html",
    "image_url": "http:\/\/balistreri.com\/sapiente-qui-qui-eveniet-enim-recusandae",
    "company_uuid": "ecd24580-2749-11ec-9b86-1102c06e74b4",
    "description": "We are helping take your business to the next level. Hop in!"
};

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

Request      

PATCH api/v1/companies/{company_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string  optional  

optional The name of the company. Example: Smarter Launch

phone   string  optional  

optional The last name of the company. Example: 5554448888

email   string  optional  

optional The email of the company. Example: hello@smarterlaunch.com

address1   string  optional  

optional The address of the company. Example: '123 Smarter Launch Way'

address2   string  optional  

optional The address of the company. Example: 'Suite 101'

city   string  optional  

optional The company city name. Example: Queen Creek

country_state_uuid   string  optional  

optional The company state uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

country_uuid   string  optional  

optional The company country uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

postal_code   string  optional  

optional The postal code of the company. Example: 85410

latitude   string  optional  

optional The latitude of the company. Example: 23.0396

longitude   string  optional  

optional The longitude of the company. Example: 72.566

primary_color   string  optional  

optional The primary color. Example: #009CFF

secondary_color   string  optional  

optional The secondary color. Example: #FFFFFF

custom_settings   object  optional  
settings   object  optional  
available_integration_uuids   object  optional  
website_url   string  optional  

Must be a valid URL. Example: http://nitzsche.com/

google_my_business_listing   string  optional  

Must be a valid URL. Example: https://wuckert.biz/et-tempore-delectus-cupiditate-sed-sed-eos-est.html

image_url   string  optional  

Example: http://balistreri.com/sapiente-qui-qui-eveniet-enim-recusandae

company_uuid   string  optional  

optional The uuid of the company. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

description   string  optional  

optional The company description. Example: We are helping take your business to the next level. Hop in!

requires authentication

Only self can remove his logo.

Redirect to Stripe Billing Auth

requires authentication

This endpoint lets user to redirect to Stripe Billing Auth.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/billing" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/billing';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/billing"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/billing

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

uuid   string   

The company uuid. Example: ecd24580-2749-11ec-9b86-1102c06e74b4

Get settings JSON file URL

requires authentication

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/settings-json" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"settings_name\": \"in\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/settings-json';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'settings_name' => 'in',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/settings-json"
);

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

let body = {
    "settings_name": "in"
};

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

Request      

GET api/v1/companies/{company_uuid}/settings-json

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

uuid   string   

The company uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Body Parameters

settings_name   string   

The setting name Example: in

POST Upload Base64 files to S3

requires authentication

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/upload-base64" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"items\": null,
    \"deleteItems\": null
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/upload-base64';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'items' => null,
            'deleteItems' => null,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/upload-base64"
);

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

let body = {
    "items": null,
    "deleteItems": null
};

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

Request      

POST api/v1/companies/{company_uuid}/upload-base64

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

items   string[]   

The array of {base64String, uuid} object.

deleteItems   string[]   

The array of uuid object.

Customer Address

API for customer address

Update

requires authentication

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f/customer-addresses" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"addresses[]\": null,
    \"delete_addresses[]\": null
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f/customer-addresses';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'addresses[]' => null,
            'delete_addresses[]' => null,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f/customer-addresses"
);

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

let body = {
    "addresses[]": null,
    "delete_addresses[]": null
};

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

Request      

PUT api/v1/customers/{customer_uuid}/customer-addresses

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

customer_uuid   string  optional  

uuid required The UUID of the customer that is to be updated. Example: 3245d634-24fd-11ec-accd-e397aec85c7f

Body Parameters

addresses[]   string[]  optional  

of addresses.

delete_addresses[]   string[]  optional  

of addresses.uuid to be deleted.

Patch

requires authentication

Patch Customer Address

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/customers/1/customer-addresses/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"address1\": \"nesciunt\",
    \"address2\": \"sunt\",
    \"city\": \"voluptatem\",
    \"country_state_uuid\": \"5b52dfc6-6a0c-3957-b7f0-ad5e83070ab6\",
    \"country_uuid\": \"a2efbd52-6fe8-3cf5-8ea5-d9712c24db45\",
    \"postal_code\": \"assumenda\",
    \"latitude\": \"voluptatibus\",
    \"longitude\": \"aut\",
    \"is_primary\": \"est\",
    \"settings\": \"ut\",
    \"county\": \"illum\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/customers/1/customer-addresses/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'address1' => 'nesciunt',
            'address2' => 'sunt',
            'city' => 'voluptatem',
            'country_state_uuid' => '5b52dfc6-6a0c-3957-b7f0-ad5e83070ab6',
            'country_uuid' => 'a2efbd52-6fe8-3cf5-8ea5-d9712c24db45',
            'postal_code' => 'assumenda',
            'latitude' => 'voluptatibus',
            'longitude' => 'aut',
            'is_primary' => 'est',
            'settings' => 'ut',
            'county' => 'illum',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/customers/1/customer-addresses/1"
);

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

let body = {
    "address1": "nesciunt",
    "address2": "sunt",
    "city": "voluptatem",
    "country_state_uuid": "5b52dfc6-6a0c-3957-b7f0-ad5e83070ab6",
    "country_uuid": "a2efbd52-6fe8-3cf5-8ea5-d9712c24db45",
    "postal_code": "assumenda",
    "latitude": "voluptatibus",
    "longitude": "aut",
    "is_primary": "est",
    "settings": "ut",
    "county": "illum"
};

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

Request      

PATCH api/v1/customers/{customer_uuid}/customer-addresses/{customerAddress_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

customer_uuid   integer   

Example: 1

customerAddress_uuid   integer   

Example: 1

Body Parameters

address1   string  optional  

optional The address 1. Example : Address 1 Example: nesciunt

address2   string  optional  

optional The address 2. Example : Address 2 Example: sunt

city   string  optional  

optional The city. Example : Queen Creek Example: voluptatem

country_state_uuid   string  optional  

optional The state uuid. Example : 3245d630-24fd-11ec-accd-e397aec85c7f Example: 5b52dfc6-6a0c-3957-b7f0-ad5e83070ab6

country_uuid   string  optional  

optional The country uuid. Example : 3245d630-24fd-11ec-accd-e397aec85c7f Example: a2efbd52-6fe8-3cf5-8ea5-d9712c24db45

postal_code   string  optional  

optional The postal code. Example : 12345 Example: assumenda

latitude   string  optional  

optional The latitude. Example : 33.2486 Example: voluptatibus

longitude   string  optional  

optional The longitude. Example : 111.6377 Example: aut

is_primary   string  optional  

optional The is_primary. Example : true Example: est

settings   string  optional  

optional The settings. Example : {} Example: ut

county   string  optional  

optional The county. Example : Pinal County Example: illum

Integration Data

requires authentication

Get data from a 3rd party API

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f/customer-addresses/1/integration-data" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"addresses[]\": null,
    \"delete_addresses[]\": null
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f/customer-addresses/1/integration-data';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'addresses[]' => null,
            'delete_addresses[]' => null,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f/customer-addresses/1/integration-data"
);

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

let body = {
    "addresses[]": null,
    "delete_addresses[]": null
};

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

Request      

GET api/v1/customers/{customer_uuid}/customer-addresses/{customerAddress_uuid}/integration-data

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

customer_uuid   string  optional  

uuid required The UUID of the customer that is to be updated. Example: 3245d634-24fd-11ec-accd-e397aec85c7f

customerAddress_uuid   integer   

Example: 1

Body Parameters

addresses[]   string[]  optional  

of addresses.

delete_addresses[]   string[]  optional  

of addresses.uuid to be deleted.

Service Plan Pricing Group

API for Service Plan Pricing Group

List

requires authentication

Shows the list of Service Plan Pricing Group with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups"
);

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

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

Request      

GET api/v1/service-plans/{servicePlan_uuid}/pricing-groups

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

page   integer  optional  

The page number. Example : 1 Example: 10

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 1

sort_by   string  optional  

The column name. Example : name Example: corrupti

sort_order   string  optional  

The order in which you want your records. Example : asc Example: et

search   string  optional  

The general search, it will find matching string. Example : home Example: sequi

Create

requires authentication

Store a newly created Service Plan Pricing Group.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"pricing_group\": [],
    \"name\": \"Premium Service Plan Pricing Group\",
    \"frequency\": \"MONTHLY\",
    \"pricing_type\": \"DYNAMIC_RANGE_PRICE\",
    \"apply_taxes\": true,
    \"description\": \"Lorem ipsum dolor sit amet, consectetur adipisicing elit...\",
    \"pricing_data\": {
        \"type\": \"The Price\",
        \"default\": \"The Pricing\",
        \"max\": \"1000.00\"
    }
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'pricing_group' => [],
            'name' => 'Premium Service Plan Pricing Group',
            'frequency' => 'MONTHLY',
            'pricing_type' => 'DYNAMIC_RANGE_PRICE',
            'apply_taxes' => true,
            'description' => 'Lorem ipsum dolor sit amet, consectetur adipisicing elit...',
            'pricing_data' => [
                'type' => 'The Price',
                'default' => 'The Pricing',
                'max' => '1000.00',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups"
);

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

let body = {
    "pricing_group": [],
    "name": "Premium Service Plan Pricing Group",
    "frequency": "MONTHLY",
    "pricing_type": "DYNAMIC_RANGE_PRICE",
    "apply_taxes": true,
    "description": "Lorem ipsum dolor sit amet, consectetur adipisicing elit...",
    "pricing_data": {
        "type": "The Price",
        "default": "The Pricing",
        "max": "1000.00"
    }
};

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

Request      

POST api/v1/service-plans/{servicePlan_uuid}/pricing-groups

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

Body Parameters

pricing_group   object   
name   string   

The name of Service Plan Pricing Group. Example: Premium Service Plan Pricing Group

frequency   string   

The frequency of Service Plan Pricing Group. Example: MONTHLY

pricing_type   string  optional  

The pricing type of Service Plan Pricing Group. Example: DYNAMIC_RANGE_PRICE

apply_taxes   boolean  optional  

The support request details. Example: true

description   string  optional  

The support request details. Example: Lorem ipsum dolor sit amet, consectetur adipisicing elit...

pricing_data   object  optional  

The support request details.

Update (Single/Multiple)

requires authentication

Modify the specified Service Plan Pricing Group. For Single update, body parameter are all required. For Multiple update, @bodyparameter will be an array of the Single @bodyParameter (if uuid is included then perform update; else, create new).

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"pricing_group\": [],
    \"save_service_plan_as\": \"SERVICE_PLAN_DRAFT\",
    \"name\": \"Premium Service Plan Pricing Group\",
    \"frequency\": \"MONTHLY\",
    \"pricing_type\": \"DYNAMIC_RANGE_PRICE\",
    \"apply_taxes\": true,
    \"description\": \"Lorem ipsum dolor sit amet, consectetur adipisicing elit...\",
    \"pricing_data\": {
        \"type\": \"The Price\",
        \"default\": \"The Pricing\",
        \"max\": \"1000.00\"
    }
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'pricing_group' => [],
            'save_service_plan_as' => 'SERVICE_PLAN_DRAFT',
            'name' => 'Premium Service Plan Pricing Group',
            'frequency' => 'MONTHLY',
            'pricing_type' => 'DYNAMIC_RANGE_PRICE',
            'apply_taxes' => true,
            'description' => 'Lorem ipsum dolor sit amet, consectetur adipisicing elit...',
            'pricing_data' => [
                'type' => 'The Price',
                'default' => 'The Pricing',
                'max' => '1000.00',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups"
);

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

let body = {
    "pricing_group": [],
    "save_service_plan_as": "SERVICE_PLAN_DRAFT",
    "name": "Premium Service Plan Pricing Group",
    "frequency": "MONTHLY",
    "pricing_type": "DYNAMIC_RANGE_PRICE",
    "apply_taxes": true,
    "description": "Lorem ipsum dolor sit amet, consectetur adipisicing elit...",
    "pricing_data": {
        "type": "The Price",
        "default": "The Pricing",
        "max": "1000.00"
    }
};

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

Request      

PUT api/v1/service-plans/{servicePlan_uuid}/pricing-groups

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

Body Parameters

pricing_group   object   
pricing_group_rules   object  optional  
save_service_plan_as   string  optional  

Example: SERVICE_PLAN_DRAFT

Must be one of:
  • SERVICE_PLAN_DRAFT
  • SERVICE_PLAN_ACTIVE
  • SERVICE_PLAN_ARCHIVED
name   string   

The name of Service Plan Pricing Group. Example: Premium Service Plan Pricing Group

frequency   string   

The frequency of Service Plan Pricing Group. Example: MONTHLY

pricing_type   string   

The pricing type of Service Plan Pricing Group. Example: DYNAMIC_RANGE_PRICE

apply_taxes   boolean   

The support request details. Example: true

description   string   

The support request details. Example: Lorem ipsum dolor sit amet, consectetur adipisicing elit...

pricing_data   object   

The support request details.

Get

requires authentication

Display the specified Service Plan Pricing Group.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups/cc5840e2-d901-34d0-8e3f-0cd85e565455" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups/cc5840e2-d901-34d0-8e3f-0cd85e565455';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups/cc5840e2-d901-34d0-8e3f-0cd85e565455"
);

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

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

Request      

GET api/v1/service-plans/{servicePlan_uuid}/pricing-groups/{servicePlanPricingGroup_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

servicePlanPricingGroup_uuid   string   

Example: cc5840e2-d901-34d0-8e3f-0cd85e565455

Update (Single/Multiple)

requires authentication

Modify the specified Service Plan Pricing Group. For Single update, body parameter are all required. For Multiple update, @bodyparameter will be an array of the Single @bodyParameter (if uuid is included then perform update; else, create new).

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups/f8c3d015-08db-3a8e-806b-6517abc4ca82" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"pricing_group\": [],
    \"save_service_plan_as\": \"SERVICE_PLAN_DRAFT\",
    \"name\": \"Premium Service Plan Pricing Group\",
    \"frequency\": \"MONTHLY\",
    \"pricing_type\": \"DYNAMIC_RANGE_PRICE\",
    \"apply_taxes\": true,
    \"description\": \"Lorem ipsum dolor sit amet, consectetur adipisicing elit...\",
    \"pricing_data\": {
        \"type\": \"The Price\",
        \"default\": \"The Pricing\",
        \"max\": \"1000.00\"
    }
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups/f8c3d015-08db-3a8e-806b-6517abc4ca82';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'pricing_group' => [],
            'save_service_plan_as' => 'SERVICE_PLAN_DRAFT',
            'name' => 'Premium Service Plan Pricing Group',
            'frequency' => 'MONTHLY',
            'pricing_type' => 'DYNAMIC_RANGE_PRICE',
            'apply_taxes' => true,
            'description' => 'Lorem ipsum dolor sit amet, consectetur adipisicing elit...',
            'pricing_data' => [
                'type' => 'The Price',
                'default' => 'The Pricing',
                'max' => '1000.00',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups/f8c3d015-08db-3a8e-806b-6517abc4ca82"
);

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

let body = {
    "pricing_group": [],
    "save_service_plan_as": "SERVICE_PLAN_DRAFT",
    "name": "Premium Service Plan Pricing Group",
    "frequency": "MONTHLY",
    "pricing_type": "DYNAMIC_RANGE_PRICE",
    "apply_taxes": true,
    "description": "Lorem ipsum dolor sit amet, consectetur adipisicing elit...",
    "pricing_data": {
        "type": "The Price",
        "default": "The Pricing",
        "max": "1000.00"
    }
};

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

Request      

PUT api/v1/service-plans/{servicePlan_uuid}/pricing-groups/{servicePlanPricingGroup_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

servicePlanPricingGroup_uuid   string   

Example: f8c3d015-08db-3a8e-806b-6517abc4ca82

Body Parameters

pricing_group   object   
pricing_group_rules   object  optional  
save_service_plan_as   string  optional  

Example: SERVICE_PLAN_DRAFT

Must be one of:
  • SERVICE_PLAN_DRAFT
  • SERVICE_PLAN_ACTIVE
  • SERVICE_PLAN_ARCHIVED
name   string   

The name of Service Plan Pricing Group. Example: Premium Service Plan Pricing Group

frequency   string   

The frequency of Service Plan Pricing Group. Example: MONTHLY

pricing_type   string   

The pricing type of Service Plan Pricing Group. Example: DYNAMIC_RANGE_PRICE

apply_taxes   boolean   

The support request details. Example: true

description   string   

The support request details. Example: Lorem ipsum dolor sit amet, consectetur adipisicing elit...

pricing_data   object   

The support request details.

Patch

requires authentication

Perform patches for the specified Service Plan Pricing Group.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups/97db7140-31bd-3384-abfe-3d5454d708e0" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Premium Service Plan Pricing Group\",
    \"frequency\": \"MONTHLY\",
    \"pricing_type\": \"DYNAMIC_RANGE_PRICE\",
    \"apply_taxes\": true,
    \"description\": \"Lorem ipsum dolor sit amet, consectetur adipisicing elit...\",
    \"pricing_data\": {
        \"type\": \"The Price\",
        \"default\": \"The Pricing\",
        \"max\": \"1000.00\"
    }
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups/97db7140-31bd-3384-abfe-3d5454d708e0';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Premium Service Plan Pricing Group',
            'frequency' => 'MONTHLY',
            'pricing_type' => 'DYNAMIC_RANGE_PRICE',
            'apply_taxes' => true,
            'description' => 'Lorem ipsum dolor sit amet, consectetur adipisicing elit...',
            'pricing_data' => [
                'type' => 'The Price',
                'default' => 'The Pricing',
                'max' => '1000.00',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups/97db7140-31bd-3384-abfe-3d5454d708e0"
);

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

let body = {
    "name": "Premium Service Plan Pricing Group",
    "frequency": "MONTHLY",
    "pricing_type": "DYNAMIC_RANGE_PRICE",
    "apply_taxes": true,
    "description": "Lorem ipsum dolor sit amet, consectetur adipisicing elit...",
    "pricing_data": {
        "type": "The Price",
        "default": "The Pricing",
        "max": "1000.00"
    }
};

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

Request      

PATCH api/v1/service-plans/{servicePlan_uuid}/pricing-groups/{servicePlanPricingGroup_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

servicePlanPricingGroup_uuid   string   

Example: 97db7140-31bd-3384-abfe-3d5454d708e0

Body Parameters

name   string  optional  

The name of Service Plan Pricing Group. Example: Premium Service Plan Pricing Group

frequency   string  optional  

The frequency of Service Plan Pricing Group. Example: MONTHLY

pricing_type   string  optional  

The pricing type of Service Plan Pricing Group. Example: DYNAMIC_RANGE_PRICE

apply_taxes   boolean  optional  

The support request details. Example: true

description   string  optional  

The support request details. Example: Lorem ipsum dolor sit amet, consectetur adipisicing elit...

pricing_data   object  optional  

The support request details.

Delete

requires authentication

Remove the specified Service Plan Pricing Group.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups/92954cee-3509-3a61-9b4e-0154f7744095" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups/92954cee-3509-3a61-9b4e-0154f7744095';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/service-plans/2/pricing-groups/92954cee-3509-3a61-9b4e-0154f7744095"
);

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

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

Request      

DELETE api/v1/service-plans/{servicePlan_uuid}/pricing-groups/{servicePlanPricingGroup_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

servicePlan_uuid   integer   

Example: 2

servicePlanPricingGroup_uuid   string   

Example: 92954cee-3509-3a61-9b4e-0154f7744095

Report

API for report related data

GET api/v1/reports/types

requires authentication

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/reports/types" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/reports/types';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/reports/types"
);

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

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

Request      

GET api/v1/reports/types

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

List

requires authentication

Returns the list of available reports

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/reports" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/reports';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/reports"
);

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

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

Request      

GET api/v1/reports

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 13

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 5

sort_by   string  optional  

The column name. Example : title Example: deserunt

sort_order   string  optional  

The order in which you want your records. Example : asc Example: laborum

search   string  optional  

The general search, it will find matching string. Example : home Example: aut

filter_by_uuids   string  optional  

string[] To filter by selected uuids. Example : [uuid, uuid-2] Example: iusto

groups   string  optional  

string[] To filter by selected groups. Example : [dashboard, sales] Example: ipsum

report_type   string  optional  

To filter by selected report type. Example : 3245d630-24fd-11ec-accd-e397aec85c7f Example: autem

template   string  optional  

To filter by selected template. Example : 3245d630-24fd-11ec-accd-e397aec85c7f Example: ratione

uuid   string  optional  

optional The company uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Store

requires authentication

Store a newly created report.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/reports" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/reports';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/reports"
);

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

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

Request      

POST api/v1/reports

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Duplicate

requires authentication

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/reports/1/duplicate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/reports/1/duplicate';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/reports/1/duplicate"
);

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

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

Request      

POST api/v1/reports/{report_uuid}/duplicate

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

report_uuid   integer   

Example: 1

Show

requires authentication

Show admin overview report.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/reports/admin-overview" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/reports/admin-overview';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/reports/admin-overview"
);

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

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

Request      

GET api/v1/reports/admin-overview

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Show

requires authentication

Show a single report.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/reports/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/reports/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/reports/1"
);

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

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

Request      

GET api/v1/reports/{report_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

report_uuid   integer   

Example: 1

user_uuid   string  optional  

optional string The user uuid. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: a72d56b1-f763-34bc-b48a-f92c5b5a35f5

period   string  optional  

optional array The period type. Example : [['period_type' => 'days', 'period_detail' => [1, 7, 30, 365]], ['period_type' => 'months', 'period_detail' => ['2023-01-01', '2023-02-02']]] Example: vero

company_location_uuid   string  optional  

optional string The company location uuid. Example : "815d3d9c-f371-3781-8456-7e6954b5b0f5" Example: 8bee44d3-4495-3aa1-b253-b726533cdb65

Export

requires authentication

Export summary reports

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/reports/1/export" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/reports/1/export';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/reports/1/export"
);

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

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

Request      

GET api/v1/reports/{report_uuid}/export

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

report_uuid   integer   

Example: 1

Filters

requires authentication

Retrieve filters to be used in frontend processes

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/reports/1/filters" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/reports/1/filters';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/reports/1/filters"
);

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

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

Request      

GET api/v1/reports/{report_uuid}/filters

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

report_uuid   integer   

Example: 1

Delete

requires authentication

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/reports/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/reports/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/reports/1"
);

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

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

Request      

DELETE api/v1/reports/{report_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

report_uuid   integer   

Example: 1

ImportSet

API for ImportSet

Apply Import Set to Company

requires authentication

Store a newly created import set.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/import-defaults" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"tags\": [
        \"aut\"
    ],
    \"import_files\": \"ut\",
    \"override\": false,
    \"admin_only\": false
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/import-defaults';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'tags' => [
                'aut',
            ],
            'import_files' => 'ut',
            'override' => false,
            'admin_only' => false,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/import-defaults"
);

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

let body = {
    "tags": [
        "aut"
    ],
    "import_files": "ut",
    "override": false,
    "admin_only": false
};

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

Request      

POST api/v1/companies/{company_uuid}/import-defaults

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

tags   string[]   

The array of tags to be associated in an import set. Example : ["Pest Control", "Arizona"]

import_files   files   

The set of json files containing import settings data. Example: ut

override   boolean   

Determine if the import set will replace the current ones with matchinig names. Example : false Example: false

admin_only   boolean   

Determine if the import set is only accessible by admin. Example : true Example: false

Apply Import Set to Company

requires authentication

Store a newly created import set.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/import-defaults/upload" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"tags\": [
        \"ipsam\"
    ],
    \"import_files\": \"natus\",
    \"override\": true,
    \"admin_only\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/import-defaults/upload';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'tags' => [
                'ipsam',
            ],
            'import_files' => 'natus',
            'override' => true,
            'admin_only' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/import-defaults/upload"
);

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

let body = {
    "tags": [
        "ipsam"
    ],
    "import_files": "natus",
    "override": true,
    "admin_only": true
};

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

Request      

POST api/v1/companies/{company_uuid}/import-defaults/upload

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

tags   string[]   

The array of tags to be associated in an import set. Example : ["Pest Control", "Arizona"]

import_files   files   

The set of json files containing import settings data. Example: natus

override   boolean   

Determine if the import set will replace the current ones with matchinig names. Example : false Example: true

admin_only   boolean   

Determine if the import set is only accessible by admin. Example : true Example: true

List

requires authentication

Shows the list of import set with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/import-sets" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/import-sets';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/import-sets"
);

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

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

Request      

GET api/v1/import-sets

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 14

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 3

sort_by   string  optional  

The column name. Example : name Example: maiores

sort_order   string  optional  

The order in which you want your records. Example : asc Example: inventore

search   string  optional  

The general search, it will find matching string. Example : "Quality Assurance" Example: quam

type_name   string  optional  

Filter by import type name : "Categories" Example: qui

type_code   string  optional  

Filter by import type name : "categories" Example: voluptas

Body Parameters

type_name   string  optional  
type_code   string  optional  

Show

requires authentication

Show a single import set.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/import-sets/23" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/import-sets/23';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/import-sets/23"
);

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

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

Request      

GET api/v1/import-sets/{importSet_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

importSet_uuid   integer   

Example: 23

Download

requires authentication

Download a single import set.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/import-sets/23/download" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/import-sets/23/download';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/import-sets/23/download"
);

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

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

Request      

GET api/v1/import-sets/{importSet_uuid}/download

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

importSet_uuid   integer   

Example: 23

Store

requires authentication

Store a newly created import set.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/import-sets" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"tags\": [
        \"sunt\"
    ],
    \"import_files\": \"incidunt\",
    \"override\": true,
    \"admin_only\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/import-sets';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'tags' => [
                'sunt',
            ],
            'import_files' => 'incidunt',
            'override' => true,
            'admin_only' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/import-sets"
);

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

let body = {
    "tags": [
        "sunt"
    ],
    "import_files": "incidunt",
    "override": true,
    "admin_only": true
};

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

Request      

POST api/v1/import-sets

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

tags   string[]   

The array of tags to be associated in an import set. Example : ["Pest Control", "Arizona"]

import_files   files   

The set of json files containing import settings data. Example: incidunt

override   boolean   

Determine if the import set will replace the current ones with matchinig names. Example : false Example: true

admin_only   boolean   

Determine if the import set is only accessible by admin. Example : true Example: true

Update

requires authentication

Update a import set.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/import-sets/23" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"import_files\": \"quam\",
    \"admin_only\": true,
    \"is_selected\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/import-sets/23';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'import_files' => 'quam',
            'admin_only' => true,
            'is_selected' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/import-sets/23"
);

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

let body = {
    "import_files": "quam",
    "admin_only": true,
    "is_selected": true
};

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

Request      

PUT api/v1/import-sets/{importSet_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

importSet_uuid   integer   

Example: 23

Body Parameters

import_files   files   

The set of json files containing import settings data. Example: quam

admin_only   boolean   

Determine if the import set is only accessible by admin. Example : true Example: true

is_selected   boolean   

Determine if the import set will be automatically selected when popping the dialog. Example : true Example: true

Update the specified resource in storage.

requires authentication

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/import-sets/23" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"admin_only\": true,
    \"is_selected\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/import-sets/23';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'admin_only' => true,
            'is_selected' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/import-sets/23"
);

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

let body = {
    "admin_only": true,
    "is_selected": true
};

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

Request      

PATCH api/v1/import-sets/{importSet_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

importSet_uuid   integer   

Example: 23

Body Parameters

admin_only   boolean   

Determine if the import set is only accessible by admin. Example : true Example: true

is_selected   boolean   

Determine if the import set will be automatically selected when popping the dialog. Example : true Example: true

Delete

requires authentication

Delete a import set.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/import-sets/23" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/import-sets/23';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/import-sets/23"
);

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

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

Request      

DELETE api/v1/import-sets/{importSet_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

importSet_uuid   integer   

Example: 23

List Forms

requires authentication

Shows the list of import set with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/form-import-sets" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/form-import-sets';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/form-import-sets"
);

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

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

Request      

GET api/v1/form-import-sets

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 12

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 5

sort_by   string  optional  

The column name. Example : name Example: hic

sort_order   string  optional  

The order in which you want your records. Example : asc Example: qui

search   string  optional  

The general search, it will find matching string. Example : "Quality Assurance" Example: expedita

Apply Import Set to Company

requires authentication

Store a newly created import set.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/form-import-sets" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"tags\": [
        \"blanditiis\"
    ],
    \"import_files\": \"et\",
    \"override\": true,
    \"admin_only\": false
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/form-import-sets';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'tags' => [
                'blanditiis',
            ],
            'import_files' => 'et',
            'override' => true,
            'admin_only' => false,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/form-import-sets"
);

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

let body = {
    "tags": [
        "blanditiis"
    ],
    "import_files": "et",
    "override": true,
    "admin_only": false
};

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

Request      

POST api/v1/form-import-sets

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

tags   string[]   

The array of tags to be associated in an import set. Example : ["Pest Control", "Arizona"]

import_files   files   

The set of json files containing import settings data. Example: et

override   boolean   

Determine if the import set will replace the current ones with matchinig names. Example : false Example: true

admin_only   boolean   

Determine if the import set is only accessible by admin. Example : true Example: false

Form

API for Form

List

requires authentication

Shows the list of form with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/forms

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 4

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 17

sort_by   string  optional  

The column name. Example : name Example: placeat

sort_order   string  optional  

The order in which you want your records. Example : asc Example: velit

search   string  optional  

The general search, it will find matching string. Example : "Quality Assurance" Example: corporis

Get form types

requires authentication

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/form-types" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/form-types';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/form-types"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/form-types

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Show

requires authentication

Show a single form.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/forms/{form_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

Store

requires authentication

Store a newly created form.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"aut\",
    \"assignment\": \"provident\",
    \"form_fields\": [
        \"assumenda\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'aut',
            'assignment' => 'provident',
            'form_fields' => [
                'assumenda',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms"
);

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

let body = {
    "name": "aut",
    "assignment": "provident",
    "form_fields": [
        "assumenda"
    ]
};

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

Request      

POST api/v1/companies/{company_uuid}/forms

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the form. Example : "My form" Example: aut

assignment   string   

The terms of the form ("QUALITY_ASSURANCE", "SERVICE_PLANS", "PROPOSAL_TEMPLATES"). Example : "QUALITY_ASSURANCE" Example: provident

form_fields   string[]  optional  

The list of form field data.

*   object  optional  
label   string  optional  

The label of a form field. Example : "Form Field 1" Example: quaerat

input_type   string  optional  

The input_type of a form field ('TEXT,NUMBER,TEXT_EDITOR,SELECT,MULTI_SELECT,CHECKBOX,DATE'). Example : "MULTI_SELECT" Example: nisi

default_value   string  optional  

The default value of the form field. Example : "Yes\n No" Example: labore

is_required   boolean  optional  

The indicator if form field is required. Example : true Example: false

is_conditional   boolean  optional  

The indicator if form field is conditional. Example : true Example: false

has_help_guide   boolean  optional  

The indicator if form field has a help guide. Example : true Example: false

conditional_value   object  optional  

A json of conditional_value of the form fiel. Example : {"conditional_value":{"form_field_id":123,"operator":"HAS_NO_VALUE"}}

help_guide   string  optional  

The help guide of the form fiel. Example : "This field is to select Yes or No" Example: nulla

position   integer  optional  

A position of the form fiel. Example : 1 Example: 6

Duplicate

requires authentication

Duplicate form

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/duplicate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/duplicate';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2/duplicate"
);

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

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

Request      

POST api/v1/companies/{company_uuid}/forms/{form_uuid}/duplicate

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

Update

requires authentication

Update a form.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"placeat\",
    \"assignment\": \"est\",
    \"form_fields\": [
        \"deserunt\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'placeat',
            'assignment' => 'est',
            'form_fields' => [
                'deserunt',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2"
);

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

let body = {
    "name": "placeat",
    "assignment": "est",
    "form_fields": [
        "deserunt"
    ]
};

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

Request      

PUT api/v1/companies/{company_uuid}/forms/{form_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

Body Parameters

name   string   

The name of the form. Example : "My Edited Form" Example: placeat

assignment   string   

The terms of the form ("QUALITY_ASSURANCE", "SERVICE_PLANS", "PROPOSAL_TEMPLATES"). Example : "QUALITY_ASSURANCE" Example: est

form_fields   string[]  optional  

The list of form field data.

*   object  optional  
label   string  optional  

The label of a form field. Example : "Form Field 1" Example: eum

input_type   string  optional  

The input_type of a form field ('TEXT,NUMBER,TEXT_EDITOR,SELECT,MULTI_SELECT,CHECKBOX,DATE'). Example : "MULTI_SELECT" Example: facilis

default_value   string  optional  

The default value of the form field. Example : "Yes\n No" Example: aut

is_required   boolean  optional  

The indicator if form field is required. Example : true Example: false

is_conditional   boolean  optional  

The indicator if form field is conditional. Example : true Example: false

has_help_guide   boolean  optional  

The indicator if form field has a help guide. Example : true Example: true

conditional_value   object  optional  

A json of conditional_value of the form field. Example : {"conditional_value":{"form_field_id":123,"operator":"HAS_NO_VALUE"}}

help_guide   string  optional  

The help guide of the form field. Example : "This field is to select Yes or No" Example: in

position   integer  optional  

A position of the form field. Example : 1 Example: 17

Update

requires authentication

Update a form.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"dolorum\",
    \"assignment\": \"natus\",
    \"form_fields\": [
        \"velit\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'dolorum',
            'assignment' => 'natus',
            'form_fields' => [
                'velit',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2"
);

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

let body = {
    "name": "dolorum",
    "assignment": "natus",
    "form_fields": [
        "velit"
    ]
};

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

Request      

POST api/v1/companies/{company_uuid}/forms/{form_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

Body Parameters

name   string   

The name of the form. Example : "My Edited Form" Example: dolorum

assignment   string   

The terms of the form ("QUALITY_ASSURANCE", "SERVICE_PLANS", "PROPOSAL_TEMPLATES"). Example : "QUALITY_ASSURANCE" Example: natus

form_fields   string[]  optional  

The list of form field data.

*   object  optional  
label   string  optional  

The label of a form field. Example : "Form Field 1" Example: quis

input_type   string  optional  

The input_type of a form field ('TEXT,NUMBER,TEXT_EDITOR,SELECT,MULTI_SELECT,CHECKBOX,DATE'). Example : "MULTI_SELECT" Example: voluptatem

default_value   string  optional  

The default value of the form field. Example : "Yes\n No" Example: sit

is_required   boolean  optional  

The indicator if form field is required. Example : true Example: true

is_conditional   boolean  optional  

The indicator if form field is conditional. Example : true Example: true

has_help_guide   boolean  optional  

The indicator if form field has a help guide. Example : true Example: false

conditional_value   object  optional  

A json of conditional_value of the form field. Example : {"conditional_value":{"form_field_id":123,"operator":"HAS_NO_VALUE"}}

help_guide   string  optional  

The help guide of the form field. Example : "This field is to select Yes or No" Example: aut

position   integer  optional  

A position of the form field. Example : 1 Example: 2

Patch

requires authentication

Patch a company form.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"error\",
    \"assignment\": \"at\",
    \"form_fields\": [
        \"voluptate\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'error',
            'assignment' => 'at',
            'form_fields' => [
                'voluptate',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2"
);

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

let body = {
    "name": "error",
    "assignment": "at",
    "form_fields": [
        "voluptate"
    ]
};

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

Request      

PATCH api/v1/companies/{company_uuid}/forms/{form_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

Body Parameters

name   string  optional  

The name of the form. Example : "My Patched Form" Example: error

assignment   string  optional  

The terms of the form ("QUALITY_ASSURANCE", "SERVICE_PLANS", "PROPOSAL_TEMPLATES"). Example : "QUALITY_ASSURANCE" Example: at

form_fields   string[]  optional  

The list of form field data.

*   object  optional  
label   string  optional  

The label of a form field. Example : "Form Field 1" Example: est

input_type   string  optional  

The input_type of a form field ('TEXT,NUMBER,TEXT_EDITOR,SELECT,MULTI_SELECT,CHECKBOX,DATE'). Example : "MULTI_SELECT" Example: totam

default_value   string  optional  

The default value of the form field. Example : "Yes\n No" Example: maxime

is_required   boolean  optional  

The indicator if form field is required. Example : true Example: true

is_conditional   boolean  optional  

The indicator if form field is conditional. Example : true Example: true

has_help_guide   boolean  optional  

The indicator if form field has a help guide. Example : true Example: true

conditional_value   object  optional  

A json of conditional_value of the form field. Example : {"conditional_value":{"form_field_id":123,"operator":"HAS_NO_VALUE"}}

help_guide   string  optional  

The help guide of the form field. Example : "This field is to select Yes or No" Example: qui

position   integer  optional  

A position of the form field. Example : 1 Example: 6

Delete

requires authentication

Delete a form.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/forms/2"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/forms/{form_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

form_uuid   integer   

Example: 2

Description Set

API for Description Set

List

requires authentication

Shows the list of description set with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/description-sets

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 6

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 2

sort_by   string  optional  

The column name. Example : name Example: commodi

sort_order   string  optional  

The order in which you want your records. Example : asc Example: accusantium

search   string  optional  

The general search, it will find matching string. Example : home Example: amet

exclude   string  optional  

array An array of UUID to exclude from the results. Example : ['3245d630-24fd-11ec-accd-e397aec85c7f'] Example: ratione

Show

requires authentication

Show a single description set.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets/1"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/description-sets/{descriptionSet_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

descriptionSet_uuid   integer   

Example: 1

Store

requires authentication

Store a newly created description set.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"consequatur\",
    \"options\": [
        \"quasi\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'consequatur',
            'options' => [
                'quasi',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets"
);

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

let body = {
    "name": "consequatur",
    "options": [
        "quasi"
    ]
};

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

Request      

POST api/v1/companies/{company_uuid}/description-sets

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the description set. Example : "Termite" Example: consequatur

options   string[]   

The options of the description set. Example : [{"title":"Termite","description":["description 1","description 2"]}]

Update

requires authentication

Update a description set.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"voluptatem\",
    \"options\": [
        \"doloribus\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'voluptatem',
            'options' => [
                'doloribus',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets/1"
);

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

let body = {
    "name": "voluptatem",
    "options": [
        "doloribus"
    ]
};

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

Request      

PUT api/v1/companies/{company_uuid}/description-sets/{descriptionSet_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

descriptionSet_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the description set. Example : "Termite" Example: voluptatem

options   string[]   

The options of the description set. Example : [{"title":"Termite","description":["description 1","description 2"]}]

Patch

requires authentication

Patch a company description set.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"molestiae\",
    \"options\": [
        \"assumenda\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'molestiae',
            'options' => [
                'assumenda',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets/1"
);

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

let body = {
    "name": "molestiae",
    "options": [
        "assumenda"
    ]
};

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

Request      

PATCH api/v1/companies/{company_uuid}/description-sets/{descriptionSet_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

descriptionSet_uuid   integer   

Example: 1

Body Parameters

name   string  optional  

The name of the description set. Example : "Termite" Example: molestiae

options   string[]  optional  

The options of the description set. Example : [{"title":"Termite","description":["description 1","description 2"]}]

Delete

requires authentication

Delete a description set.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/description-sets/1"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/description-sets/{descriptionSet_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

descriptionSet_uuid   integer   

Example: 1

Home

Index

requires authentication

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1"
);

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

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

Request      

GET api/v1

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Referral Source

API for Referral Source

List

requires authentication

Shows the list of referral sources.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/referral-sources

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 2

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 8

sort_by   string  optional  

The column name. Example : name Example: reprehenderit

sort_order   string  optional  

The order in which you want your records. Example : asc Example: voluptate

search   string  optional  

The general search, it will find matching string. Example : home Example: mollitia

Show

requires authentication

Show a single referral source.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources/1"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/referral-sources/{referralSource_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

referralSource_uuid   integer   

Example: 1

Store

requires authentication

Store a newly created referral source.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"perspiciatis\",
    \"description\": \"\\\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\\\"\",
    \"integration_source_id\": \"1234263\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'perspiciatis',
            'description' => '"Lorem ipsum dolor sit amet consectetur adipisicing elit."',
            'integration_source_id' => '1234263',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources"
);

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

let body = {
    "name": "perspiciatis",
    "description": "\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\"",
    "integration_source_id": "1234263"
};

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

Request      

POST api/v1/companies/{company_uuid}/referral-sources

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the referral source. Example : Referral Source 1 Example: perspiciatis

description   string   

The attributes of the referral source. Example: "Lorem ipsum dolor sit amet consectetur adipisicing elit."

integration_source_id   string  optional  

optional The image source id of the referral source. Example: 1234263

Update

requires authentication

Update a referral source.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"explicabo\",
    \"description\": \"\\\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\\\"\",
    \"integration_source_id\": \"1234263\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'explicabo',
            'description' => '"Lorem ipsum dolor sit amet consectetur adipisicing elit."',
            'integration_source_id' => '1234263',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources/1"
);

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

let body = {
    "name": "explicabo",
    "description": "\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\"",
    "integration_source_id": "1234263"
};

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

Request      

PUT api/v1/companies/{company_uuid}/referral-sources/{referralSource_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

referralSource_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the referral source. Example : Referral Source 1 Example: explicabo

description   string   

The attributes of the referral source. Example: "Lorem ipsum dolor sit amet consectetur adipisicing elit."

integration_source_id   string  optional  

optional The image source id of the referral source. Example: 1234263

Patch

requires authentication

Patch a company referral source.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"qui\",
    \"description\": \"\\\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\\\"\",
    \"integration_source_id\": \"1234263\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'qui',
            'description' => '"Lorem ipsum dolor sit amet consectetur adipisicing elit."',
            'integration_source_id' => '1234263',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources/1"
);

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

let body = {
    "name": "qui",
    "description": "\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\"",
    "integration_source_id": "1234263"
};

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

Request      

PATCH api/v1/companies/{company_uuid}/referral-sources/{referralSource_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

referralSource_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the referral source. Example : Referral Source 1 Example: qui

description   string   

The attributes of the referral source. Example: "Lorem ipsum dolor sit amet consectetur adipisicing elit."

integration_source_id   string  optional  

optional The image source id of the referral source. Example: 1234263

Delete

requires authentication

Delete a referral source.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/referral-sources/1"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/referral-sources/{referralSource_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

referralSource_uuid   integer   

Example: 1

Solution

API for Solution

List

requires authentication

Shows the list of solutions.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/solutions" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions"
);

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

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

Request      

GET api/v1/solutions

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 7

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 17

sort_by   string  optional  

The column name. Example : name Example: optio

sort_order   string  optional  

The order in which you want your records. Example : asc Example: sit

search   string  optional  

The general search, it will find matching string. Example : home Example: nesciunt

filter_by_solution_category_uuids   string  optional  

array To filter the list of solutions by solution category. Example : ["3c787d66-2a4f-3f1d-9591-c330be0abe82"] Example: eveniet

filter_by_status_uuid   string  optional  

To filter the list the status. Example : "3c787d66-2a4f-3f1d-9591-c330be0abe82" Example: 49781905-d97a-31e6-8e23-44f7813f6c02

Show

requires authentication

Show a single solution.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/solutions/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1"
);

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

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

Request      

GET api/v1/solutions/{solution_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solution_uuid   integer   

Example: 1

Store

requires authentication

Store a new solution.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/solutions" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"solution_category_uuid\": \"87135365-a27b-3c7a-95af-e6b3d16759b0\",
    \"name\": \"repellendus\",
    \"slug\": \"solution-1\",
    \"description\": \"\\\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\\\"\",
    \"video_url\": \"\\\"https::somevideo.com\\/thevideoforpestroutes\\\"\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'solution_category_uuid' => '87135365-a27b-3c7a-95af-e6b3d16759b0',
            'name' => 'repellendus',
            'slug' => 'solution-1',
            'description' => '"Lorem ipsum dolor sit amet consectetur adipisicing elit."',
            'video_url' => '"https::somevideo.com/thevideoforpestroutes"',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions"
);

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

let body = {
    "solution_category_uuid": "87135365-a27b-3c7a-95af-e6b3d16759b0",
    "name": "repellendus",
    "slug": "solution-1",
    "description": "\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\"",
    "video_url": "\"https::somevideo.com\/thevideoforpestroutes\""
};

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

Request      

POST api/v1/solutions

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

solution_category_uuid   uuid   

The solution category of the solution. Example : "3c787d66-2a4f-3f1d-9591-c330be0abe82" Example: 87135365-a27b-3c7a-95af-e6b3d16759b0

name   string   

The name of the solution. Example : Solution 1 Example: repellendus

slug   string  optional  

The slug of the solution category. Example: solution-1

description   string  optional  

The attributes of the solution. Example: "Lorem ipsum dolor sit amet consectetur adipisicing elit."

video_url   string  optional  

The video url of the solution. Example: "https::somevideo.com/thevideoforpestroutes"

Store Image

requires authentication

Upload an image to solution

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/solutions/upload" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "fileUpload=@/tmp/phpXhrQVS" 
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/upload';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'multipart/form-data',
            'Accept' => 'application/json',
        ],
        'multipart' => [
            [
                'name' => 'fileUpload',
                'contents' => fopen('/tmp/phpXhrQVS', 'r')
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/upload"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('fileUpload', document.querySelector('input[name="fileUpload"]').files[0]);

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

Request      

POST api/v1/solutions/upload

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: multipart/form-data

Accept      

Example: application/json

Body Parameters

fileUpload   file   

The file to be uploaded. Example: /tmp/phpXhrQVS

Update

requires authentication

Update a solution.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"solution_category_uuid\": \"5d262da8-8476-3b63-b78e-3e199eb1026d\",
    \"name\": \"ut\",
    \"slug\": \"solution-1\",
    \"description\": \"\\\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\\\"\",
    \"video_url\": \"\\\"https::somevideo.com\\/thevideoforpestroutes\\\"\",
    \"status_uuid\": \"\\\"3c787d66-2a4f-3f1d-9591-c330be0abe82\\\"\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'solution_category_uuid' => '5d262da8-8476-3b63-b78e-3e199eb1026d',
            'name' => 'ut',
            'slug' => 'solution-1',
            'description' => '"Lorem ipsum dolor sit amet consectetur adipisicing elit."',
            'video_url' => '"https::somevideo.com/thevideoforpestroutes"',
            'status_uuid' => '"3c787d66-2a4f-3f1d-9591-c330be0abe82"',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1"
);

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

let body = {
    "solution_category_uuid": "5d262da8-8476-3b63-b78e-3e199eb1026d",
    "name": "ut",
    "slug": "solution-1",
    "description": "\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\"",
    "video_url": "\"https::somevideo.com\/thevideoforpestroutes\"",
    "status_uuid": "\"3c787d66-2a4f-3f1d-9591-c330be0abe82\""
};

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

Request      

PUT api/v1/solutions/{solution_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solution_uuid   integer   

Example: 1

Body Parameters

solution_category_uuid   uuid   

The solution category of the solution. Example : "3c787d66-2a4f-3f1d-9591-c330be0abe82" Example: 5d262da8-8476-3b63-b78e-3e199eb1026d

name   string   

The name of the solution. Example : Solution 1 Example: ut

slug   string  optional  

The slug of the solution category. Example: solution-1

description   string  optional  

The attributes of the solution. Example: "Lorem ipsum dolor sit amet consectetur adipisicing elit."

video_url   string  optional  

The video url of the solution. Example: "https::somevideo.com/thevideoforpestroutes"

status_uuid   string  optional  

The video url of the solution. Example: "3c787d66-2a4f-3f1d-9591-c330be0abe82"

Reset

requires authentication

Reset a solution's user progress.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/reset" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1/reset';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/reset"
);

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

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

Request      

PUT api/v1/solutions/{solution_uuid}/reset

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solution_uuid   integer   

Example: 1

Update user progress

requires authentication

Update user progress.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/user-progress" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"is_completed\": false,
    \"step\": []
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1/user-progress';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'is_completed' => false,
            'step' => [],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/user-progress"
);

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

let body = {
    "is_completed": false,
    "step": []
};

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

Request      

PUT api/v1/solutions/{solution_uuid}/user-progress

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solution_uuid   integer   

Example: 1

Body Parameters

is_completed   boolean  optional  

The solution category of the solution. Example : false Example: false

step   object  optional  

The current step the use is on. Example : 2

Patch Index

requires authentication

Performs specific updates for solutions

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/sort" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1/sort';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1/sort"
);

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

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

Request      

PATCH api/v1/solutions/{solutionCategory_uuid}/sort

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solutionCategory_uuid   integer   

Example: 1

solutions_ranking_list   string  optional  

string[] A dictionary of uuids with uuid as key and rank as the value. Example : {"69e56cdf-cea8-4356-b35d-58d610aba886" : 1, "9c578b77-916a-4620-a246-fa951f422912" : 2} Example: aut

Patch

requires authentication

Patch a solution.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"solution_category_uuid\": \"dc2a99ed-7285-3ab2-8a02-38d70899338f\",
    \"name\": \"magnam\",
    \"slug\": \"solution-1\",
    \"description\": \"\\\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\\\"\",
    \"video_url\": \"\\\"https::somevideo.com\\/thevideoforpestroutes\\\"\",
    \"status_uuid\": \"\\\"3c787d66-2a4f-3f1d-9591-c330be0abe82\\\"\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'solution_category_uuid' => 'dc2a99ed-7285-3ab2-8a02-38d70899338f',
            'name' => 'magnam',
            'slug' => 'solution-1',
            'description' => '"Lorem ipsum dolor sit amet consectetur adipisicing elit."',
            'video_url' => '"https::somevideo.com/thevideoforpestroutes"',
            'status_uuid' => '"3c787d66-2a4f-3f1d-9591-c330be0abe82"',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1"
);

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

let body = {
    "solution_category_uuid": "dc2a99ed-7285-3ab2-8a02-38d70899338f",
    "name": "magnam",
    "slug": "solution-1",
    "description": "\"Lorem ipsum dolor sit amet consectetur adipisicing elit.\"",
    "video_url": "\"https::somevideo.com\/thevideoforpestroutes\"",
    "status_uuid": "\"3c787d66-2a4f-3f1d-9591-c330be0abe82\""
};

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

Request      

PATCH api/v1/solutions/{solution_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solution_uuid   integer   

Example: 1

Body Parameters

solution_category_uuid   uuid  optional  

The solution category of the solution. Example : "3c787d66-2a4f-3f1d-9591-c330be0abe82" Example: dc2a99ed-7285-3ab2-8a02-38d70899338f

name   string  optional  

The name of the solution. Example : Solution 1 Example: magnam

slug   string  optional  

The slug of the solution category. Example: solution-1

description   string  optional  

The attributes of the solution. Example: "Lorem ipsum dolor sit amet consectetur adipisicing elit."

video_url   string  optional  

The video url of the solution. Example: "https::somevideo.com/thevideoforpestroutes"

status_uuid   string  optional  

The video url of the solution. Example: "3c787d66-2a4f-3f1d-9591-c330be0abe82"

Delete

requires authentication

Delete a solution.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/solutions/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/solutions/1"
);

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

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

Request      

DELETE api/v1/solutions/{solution_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

solution_uuid   integer   

Example: 1

Customer

API for customers

List

requires authentication

Shows the list of company customers that the user has access to view.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/customers?page=1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"page_size\": 15,
    \"sort_by\": \"display_name\",
    \"sort_order\": \"asc\",
    \"search\": \"John\",
    \"filter_by_company_location_uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\",
    \"filter_by_statuses_uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\",
    \"is_with_trashed\": true
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/customers';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'query' => [
            'page' => '1',
        ],
        'json' => [
            'page_size' => 15,
            'sort_by' => 'display_name',
            'sort_order' => 'asc',
            'search' => 'John',
            'filter_by_company_location_uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
            'filter_by_statuses_uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
            'is_with_trashed' => true,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/customers"
);

const params = {
    "page": "1",
};
Object.keys(params)
    .forEach(key => url.searchParams.append(key, params[key]));

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

let body = {
    "page_size": 15,
    "sort_by": "display_name",
    "sort_order": "asc",
    "search": "John",
    "filter_by_company_location_uuid": "3245d630-24fd-11ec-accd-e397aec85c7f",
    "filter_by_statuses_uuid": "3245d630-24fd-11ec-accd-e397aec85c7f",
    "is_with_trashed": true
};

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

Request      

GET api/v1/customers

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Query Parameters

page   integer  optional  

optional The page number. Example: 1

Body Parameters

page_size   integer  optional  

optional The number of records you want per page. Example: 15

sort_by   string  optional  

optional The column name. Example: display_name

sort_order   string  optional  

optional The order in which you want your records. Example: asc

search   string  optional  

optional The general search, it will find matching string. Example: John

filter_by_company_location_uuid   string  optional  

uuid optional Filter results by company location uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

filter_by_statuses_uuid   string  optional  

uuid optional Filter results by company location uuid. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

is_with_trashed   boolean  optional  

Whether or not to include trashed customer, addresses and contacts. Example: true

Show

requires authentication

This endpoint returns detail of a certain customer.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/customers/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/customers/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/customers/1"
);

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

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

Request      

GET api/v1/customers/{customer_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

customer_uuid   integer   

Example: 1

Store

requires authentication

Create a new customer along with their primary contact and address

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/customers" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"company_location_uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\",
    \"account_name\": \"Smarter Launch LLC\",
    \"customer_contact\": [
        \"commodi\"
    ],
    \"customer_address\": [
        \"quidem\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/customers';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'company_location_uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
            'account_name' => 'Smarter Launch LLC',
            'customer_contact' => [
                'commodi',
            ],
            'customer_address' => [
                'quidem',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/customers"
);

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

let body = {
    "company_location_uuid": "3245d630-24fd-11ec-accd-e397aec85c7f",
    "account_name": "Smarter Launch LLC",
    "customer_contact": [
        "commodi"
    ],
    "customer_address": [
        "quidem"
    ]
};

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

Request      

POST api/v1/customers

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

company_location_uuid   uuid   

The company location UUID. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

account_name   string   

The account name. Example: Smarter Launch LLC

customer_contact   string[]   

The customer contacts

*   object  optional  
first_name   string   

The first name of the primary contact for the customer. Example: John

last_name   string   

The last name of the primary contact for the customer. Example: Smith

email   string   

The email address of the primary contact for the customer. Example: john.smith@smarterlaunch.com

phone   string   

The phone number of the primary contact for the customer. Example: 5554448888

customer_address   string[]   

The contact addresses

*   object  optional  
address1   string   

The address of the primary service address of the customer. Example: 123 Smarter Launch Way

address2   string  optional  

The extended address for the primary service address of the customer. Example: Suite 123

city   string   

The city for the primary service address of the customer. Example: Queen Creek

country_state_uuid   uuid   

The state UUID for the primary service address of the customer. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

postal_code   string   

The postal code for the primary service address of the customer. Example: 85140

country_uuid   uuid   

The country UUID for the primary service address of the customer. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Update with contact and address

requires authentication

This is to update those partial customer data

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/customers/1/with-contact-address" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"company_location_uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\",
    \"account_name\": \"Smarter Launch LLC\",
    \"customer_contact\": [
        \"maxime\"
    ],
    \"customer_address\": [
        \"laboriosam\"
    ]
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/customers/1/with-contact-address';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'company_location_uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
            'account_name' => 'Smarter Launch LLC',
            'customer_contact' => [
                'maxime',
            ],
            'customer_address' => [
                'laboriosam',
            ],
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/customers/1/with-contact-address"
);

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

let body = {
    "company_location_uuid": "3245d630-24fd-11ec-accd-e397aec85c7f",
    "account_name": "Smarter Launch LLC",
    "customer_contact": [
        "maxime"
    ],
    "customer_address": [
        "laboriosam"
    ]
};

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

Request      

PUT api/v1/customers/{customer_uuid}/with-contact-address

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

customer_uuid   integer   

Example: 1

Body Parameters

company_location_uuid   uuid   

The company location UUID. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

account_name   string   

The account name. Example: Smarter Launch LLC

customer_contact   string[]   

The customer contacts

*   object  optional  
first_name   string   

The first name of the primary contact for the customer. Example: John

last_name   string   

The last name of the primary contact for the customer. Example: Smith

email   string   

The email address of the primary contact for the customer. Example: john.smith@smarterlaunch.com

phone   string   

The phone number of the primary contact for the customer. Example: 5554448888

customer_address   string[]   

The contact addresses

*   object  optional  
address1   string   

The address of the primary service address of the customer. Example: 123 Smarter Launch Way

address2   string  optional  

The extended address for the primary service address of the customer. Example: Suite 123

city   string   

The city for the primary service address of the customer. Example: Queen Creek

country_state_uuid   uuid   

The state UUID for the primary service address of the customer. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

postal_code   string   

The postal code for the primary service address of the customer. Example: 85140

country_uuid   uuid   

The country UUID for the primary service address of the customer. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Update

requires authentication

Update individual customer account name and the location they are associated with.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"company_location_uuid\": \"3245d634-24fd-11ec-accd-e397aec85c7f\",
    \"account_name\": \"Smarter Launch LLC\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'company_location_uuid' => '3245d634-24fd-11ec-accd-e397aec85c7f',
            'account_name' => 'Smarter Launch LLC',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f"
);

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

let body = {
    "company_location_uuid": "3245d634-24fd-11ec-accd-e397aec85c7f",
    "account_name": "Smarter Launch LLC"
};

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

Request      

PUT api/v1/customers/{customer_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

customer_uuid   string  optional  

uuid required The UUID of the customer that is to be updated. Example: 3245d634-24fd-11ec-accd-e397aec85c7f

Body Parameters

company_location_uuid   uuid   

The UUID of the company location to associate the customer with. Example: 3245d634-24fd-11ec-accd-e397aec85c7f

account_name   string   

The account name. Example: Smarter Launch LLC

referral_source_uuid   string  optional  
include_fields   string  optional  

Patch

requires authentication

Patch individual customer account name and the location they are associated with.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"company_location_uuid\": \"3245d634-24fd-11ec-accd-e397aec85c7f\",
    \"account_name\": \"Smarter Launch LLC\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'company_location_uuid' => '3245d634-24fd-11ec-accd-e397aec85c7f',
            'account_name' => 'Smarter Launch LLC',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/customers/3245d634-24fd-11ec-accd-e397aec85c7f"
);

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

let body = {
    "company_location_uuid": "3245d634-24fd-11ec-accd-e397aec85c7f",
    "account_name": "Smarter Launch LLC"
};

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

Request      

PATCH api/v1/customers/{customer_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

customer_uuid   string  optional  

uuid required The UUID of the customer that is to be updated. Example: 3245d634-24fd-11ec-accd-e397aec85c7f

Body Parameters

company_location_uuid   uuid   

The UUID of the company location to associate the customer with. Example: 3245d634-24fd-11ec-accd-e397aec85c7f

account_name   string   

The account name. Example: Smarter Launch LLC

Delete

requires authentication

This end point allows user the delete the customer.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/customers/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"uuid\": \"3245d630-24fd-11ec-accd-e397aec85c7f\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/customers/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'uuid' => '3245d630-24fd-11ec-accd-e397aec85c7f',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/customers/1"
);

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

let body = {
    "uuid": "3245d630-24fd-11ec-accd-e397aec85c7f"
};

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

Request      

DELETE api/v1/customers/{customer_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

customer_uuid   integer   

Example: 1

Body Parameters

uuid   string   

The uuid of the customer. Example: 3245d630-24fd-11ec-accd-e397aec85c7f

Sync

requires authentication

This endpoint allows user to perform manual sync to a customer

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/customers/1/sync" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/customers/1/sync';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/customers/1/sync"
);

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

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

Request      

PATCH api/v1/customers/{customer_uuid}/sync

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

customer_uuid   integer   

Example: 1

Fetch all available industry

requires authentication

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/industries" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/industries';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/industries"
);

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

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

Request      

GET api/v1/industries

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Category

API for Category

List

requires authentication

Shows the list of Categories with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/categories" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/categories';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/categories"
);

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

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

Request      

GET api/v1/categories

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

page   integer  optional  

The page number. Example : 1 Example: 5

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 7

sort_by   string  optional  

The column name. Example : name Example: incidunt

sort_order   string  optional  

The order in which you want your records. Example : asc Example: accusamus

search   string  optional  

The general search, it will find matching string. Example : home Example: nostrum

category_group   string  optional  

The category group to filter by. Example : SERVICE_PLAN Example: sint

Create

requires authentication

Store a newly created Category.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/categories" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Small Pests\",
    \"description\": \"Lorem ipsum dolor sit amet consectetur adipisicing elit\",
    \"category_group\": \"SERVICE_PLAN\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/categories';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Small Pests',
            'description' => 'Lorem ipsum dolor sit amet consectetur adipisicing elit',
            'category_group' => 'SERVICE_PLAN',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/categories"
);

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

let body = {
    "name": "Small Pests",
    "description": "Lorem ipsum dolor sit amet consectetur adipisicing elit",
    "category_group": "SERVICE_PLAN"
};

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

Request      

POST api/v1/categories

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

Body Parameters

name   string   

The name of the category. Example: Small Pests

description   string  optional  

The description of the category. Example: Lorem ipsum dolor sit amet consectetur adipisicing elit

category_group   string   

The category_group of the category. ['SERVICE_PLAN']. Example: SERVICE_PLAN

Get

requires authentication

Display the specified Category.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/categories/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/categories/1';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/categories/1"
);

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

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

Request      

GET api/v1/categories/{category_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

category_uuid   integer   

Example: 1

Update

requires authentication

Modify the specified Category.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/categories/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Small Pests\",
    \"description\": \"Lorem ipsum dolor sit amet consectetur adipisicing elit\",
    \"category_group\": \"SERVICE_PLAN\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/categories/1';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Small Pests',
            'description' => 'Lorem ipsum dolor sit amet consectetur adipisicing elit',
            'category_group' => 'SERVICE_PLAN',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/categories/1"
);

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

let body = {
    "name": "Small Pests",
    "description": "Lorem ipsum dolor sit amet consectetur adipisicing elit",
    "category_group": "SERVICE_PLAN"
};

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

Request      

PUT api/v1/categories/{category_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

category_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the category. Example: Small Pests

description   string  optional  

The description of the category. Example: Lorem ipsum dolor sit amet consectetur adipisicing elit

category_group   string  optional  

Example: SERVICE_PLAN

Must be one of:
  • SERVICE_PLAN
  • DRAWING_SYMBOL

Patch

requires authentication

Perform patches for the specified Category.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/categories/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"Small Pests\",
    \"description\": \"Lorem ipsum dolor sit amet consectetur adipisicing elit\",
    \"category_group\": \"DRAWING_SYMBOL\"
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/categories/1';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'Small Pests',
            'description' => 'Lorem ipsum dolor sit amet consectetur adipisicing elit',
            'category_group' => 'DRAWING_SYMBOL',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/categories/1"
);

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

let body = {
    "name": "Small Pests",
    "description": "Lorem ipsum dolor sit amet consectetur adipisicing elit",
    "category_group": "DRAWING_SYMBOL"
};

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

Request      

PATCH api/v1/categories/{category_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

category_uuid   integer   

Example: 1

Body Parameters

name   string  optional  

The name of the category. Example: Small Pests

description   string  optional  

The description of the category. Example: Lorem ipsum dolor sit amet consectetur adipisicing elit

category_group   string  optional  

Example: DRAWING_SYMBOL

Must be one of:
  • SERVICE_PLAN
  • DRAWING_SYMBOL

Delete

requires authentication

Remove the specified Category.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/categories/1" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/categories/1';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/categories/1"
);

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

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

Request      

DELETE api/v1/categories/{category_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

category_uuid   integer   

Example: 1

Schedule

API for Schedule

List

requires authentication

Shows the list of schedule with pagination.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/schedules

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

page   integer  optional  

The page number. Example : 1 Example: 3

page_size   integer  optional  

The number of record you want per page. Example : 5 Example: 1

sort_by   string  optional  

The column name. Example : name Example: fugit

sort_order   string  optional  

The order in which you want your records. Example : asc Example: labore

search   string  optional  

The general search, it will find matching string. Example : home Example: unde

type   string  optional  

in:'service','billing' The filter by type. Example : service Example: totam

Show

requires authentication

Show a single schedule.

Example request:
curl --request GET \
    --get "https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules/2';
$response = $client->get(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules/2"
);

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

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

Request      

GET api/v1/companies/{company_uuid}/schedules/{schedule_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

schedule_uuid   integer   

Example: 2

Store

requires authentication

Store a newly created schedule.

Example request:
curl --request POST \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"non\",
    \"description\": \"Nihil ut recusandae fuga nihil repellendus voluptatem.\",
    \"type\": \"est\",
    \"units\": 14,
    \"term\": \"et\",
    \"enabled_service_months\": [
        \"vitae\"
    ],
    \"visits\": 13
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules';
$response = $client->post(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'non',
            'description' => 'Nihil ut recusandae fuga nihil repellendus voluptatem.',
            'type' => 'est',
            'units' => 14,
            'term' => 'et',
            'enabled_service_months' => [
                'vitae',
            ],
            'visits' => 13,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules"
);

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

let body = {
    "name": "non",
    "description": "Nihil ut recusandae fuga nihil repellendus voluptatem.",
    "type": "est",
    "units": 14,
    "term": "et",
    "enabled_service_months": [
        "vitae"
    ],
    "visits": 13
};

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

Request      

POST api/v1/companies/{company_uuid}/schedules

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

Body Parameters

name   string   

The name of the schedule. Example : "My Schedule" Example: non

description   string  optional  

The description of the schedule. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: Nihil ut recusandae fuga nihil repellendus voluptatem.

type   string   

The type of the schedule (service, billing). Example : "service" Example: est

units   integer   

The number of week(s)/month(s)/year(s) of a schedule. Example : 5 Example: 14

term   string   

The terms of the schedule (week/month/year). Example : week Example: et

enabled_service_months   string[]   

The list of integer which represents a month. Example : [1, 2, 12] means ["January", "February", "December"]

visits   integer  optional  

The number of visits of the schedule. Example : 52 Example: 13

Update

requires authentication

Update a schedule.

Example request:
curl --request PUT \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"dolorem\",
    \"description\": \"Ipsum minus dolor et.\",
    \"type\": \"eos\",
    \"units\": 4,
    \"term\": \"aut\",
    \"enabled_service_months\": [
        \"blanditiis\"
    ],
    \"visits\": 14
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules/2';
$response = $client->put(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'dolorem',
            'description' => 'Ipsum minus dolor et.',
            'type' => 'eos',
            'units' => 4,
            'term' => 'aut',
            'enabled_service_months' => [
                'blanditiis',
            ],
            'visits' => 14,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules/2"
);

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

let body = {
    "name": "dolorem",
    "description": "Ipsum minus dolor et.",
    "type": "eos",
    "units": 4,
    "term": "aut",
    "enabled_service_months": [
        "blanditiis"
    ],
    "visits": 14
};

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

Request      

PUT api/v1/companies/{company_uuid}/schedules/{schedule_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

schedule_uuid   integer   

Example: 2

Body Parameters

name   string   

The name of the schedule. Example : "My Schedule" Example: dolorem

description   string  optional  

The description of the schedule. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: Ipsum minus dolor et.

type   string   

The type of the schedule (service, billing). Example : "service" Example: eos

units   integer   

The number of week(s)/month(s)/year(s) of a schedule. Example : 5 Example: 4

term   string   

The terms of the schedule (week/month/year). Example : week Example: aut

enabled_service_months   string[]   

The list of integer which represents a month. Example : [1, 2, 12] means ["January", "February", "December"]

visits   integer  optional  

The number of visits of the schedule. Example : 52 Example: 14

Patch

requires authentication

Patch a company schedule.

Example request:
curl --request PATCH \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"dolore\",
    \"description\": \"Et molestiae aut officiis et dolore amet aut.\",
    \"type\": \"provident\",
    \"units\": 6,
    \"term\": \"at\",
    \"enabled_service_months\": [
        \"quod\"
    ],
    \"visits\": 8
}"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules/2';
$response = $client->patch(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
        'json' => [
            'name' => 'dolore',
            'description' => 'Et molestiae aut officiis et dolore amet aut.',
            'type' => 'provident',
            'units' => 6,
            'term' => 'at',
            'enabled_service_months' => [
                'quod',
            ],
            'visits' => 8,
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules/2"
);

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

let body = {
    "name": "dolore",
    "description": "Et molestiae aut officiis et dolore amet aut.",
    "type": "provident",
    "units": 6,
    "term": "at",
    "enabled_service_months": [
        "quod"
    ],
    "visits": 8
};

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

Request      

PATCH api/v1/companies/{company_uuid}/schedules/{schedule_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

schedule_uuid   integer   

Example: 2

Body Parameters

name   string   

The name of the schedule. Example : "My Schedule" Example: dolore

description   string  optional  

The description of the schedule. Example : "Lorem ipsum dolor sit, amet consectetur adipisicing elit. Consequatur dolores iste quae soluta." Example: Et molestiae aut officiis et dolore amet aut.

type   string   

The type of the schedule (service, billing). Example : "service" Example: provident

units   integer   

The number of week(s)/month(s)/year(s) of a schedule. Example : 5 Example: 6

term   string   

The terms of the schedule (week/month/year). Example : week Example: at

enabled_service_months   string[]   

The list of integer which represents a month. Example : [1, 2, 12] means ["January", "February", "December"]

visits   integer  optional  

The number of visits of the schedule. Example : 52 Example: 8

Delete

requires authentication

Delete a schedule.

Example request:
curl --request DELETE \
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules/2" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
$client = new \GuzzleHttp\Client();
$url = 'https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules/2';
$response = $client->delete(
    $url,
    [
        'headers' => [
            'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
            'Content-Type' => 'application/json',
            'Accept' => 'application/json',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
const url = new URL(
    "https://staging.api.smarterlaunch.com/api/v1/companies/1/schedules/2"
);

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

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

Request      

DELETE api/v1/companies/{company_uuid}/schedules/{schedule_uuid}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

company_uuid   integer   

Example: 1

schedule_uuid   integer   

Example: 2