Organizations

Properties

PropertyTypeDescription
idIntegerThe ID of the Organization.
nameStringFriendly name for the Organization.
phone_numberStringAssociated phone number.
socialArrayAn array of social media URLs.
social.facebookStringURL of Organization's Facebook Page.
social.twitterStringURL of Organization's Twitter Page.
social.instagramStringURL of Organization's Instagram Page.
social.youtubeStringURL of Organization's YouTube Page.
social.tiktokStringURL of Organization's TikTok Page.
social.pinterestStringURL of Organization's Pinterest Page.
created_atDateTimeDateTime the Organization was created in autoZnetwork's system.
updated_atDateTimeDateTime the Organization was last updated in autoZnetwork's system.

Relationships

RelationshipDescription
LocationsThe Locations contained within the Organization.
Location GroupsThe Location Groups contained within the Organization.

List Organizations

GET Request: https://api.autoznetwork.com/v1/organizations

CURL
AUTOZNETWORK_TOKEN="your API token"

curl https://api.autoznetwork.com/v1/organizations \
  -H "Authorization: Bearer $AUTOZNETWORK_TOKEN" \
  -H 'Accept: application/json'
PHP
<?php 
$apiToken = 'ABCD12345 ...';

$autoZnetwork = new AutozNetwork($apiToken);

$organizations = $autoznetwork
                  ->organizations()
                  ->get();

print($organizations)

Get an Organization

This will return an individual organization.

GET Request: https://api.autoznetwork.com/v1/organizations/{ORGANIZATION_ID}

CURL
AUTOZNETWORK_TOKEN="your API token"
AUTOZNETWORK_ORG_ID="your organization id"

curl -X GET https://api.autoznetwork.com/v1/organizations/$AUTOZNETWORK_ORG_ID \
  -H "Authorization: Bearer $AUTOZNETWORK_TOKEN" \
  -H 'Accept: application/json'

Update an Organization

You must be the owner of the organization in order to send this request.

PATCH Request: https://api.autoznetwork.com/v1/organizations/{ORGANIZATION_ID}

CURL
AUTOZNETWORK_TOKEN="your API token"
AUTOZNETWORK_ORG_ID="your organization id"

curl -X PUT https://api.autoznetwork.com/v1/organizations/$AUTOZNETWORK_ORG_ID \
  -H "Authorization: Bearer $AUTOZNETWORK_TOKEN" \
    -H 'Accept: application/json' \
    -H 'Content-Type: application/json' \
    -d '{
      "name": "your NEW organization name",
    }'

Delete an Organization

You must be the owner of the organization in order to send this request.

DELETE Request: https://api.autoznetwork.com/v1/organizations/{ORGANIZATION_ID}

CURL
AUTOZNETWORK_TOKEN="your API token"
AUTOZNETWORK_ORG_ID="your organization id"

curl -X DELETE https://api.autoznetwork.com/v1/organizations/$AUTOZNETWORK_ORG_ID \
  -H "Authorization: Bearer $AUTOZNETWORK_TOKEN" \
  -H 'Accept: application/json'