The storEDGE API is a REST API. It uses one-legged OAuth 1.0 as its authentication mechanism.
All communication is done over HTTPS, there is no non-secure access. All storEDGE URL’s adhere to the following format:
https:///:version_identifier/:facility_id/:resource((/:resource_id)((/:subresource)(/:subresource_id)))
A URL in practice would be something like:
https:///v1/843eee4355b74b2585c4c555ba7f43fa/ledgers/2c7b16bb-a760-4938-b94244f719e-05529
In other words, all storEDGE API calls have an API version and facility context based on the base URL.
The storEDGE API uses OAuth 1.0 as its authentication mechanism. Whereas in many OAuth implementations you would have three steps (application<->service, service<->user, service<->application), storEDGE uses only one leg (application<->service), hence the term "one-legged". For a description of the various OAuth 1.0 flows, please see https://github.com/Mashape/mashape-oauth/blob/master/FLOWS.md
You will need three pieces of information to communicate with the API:
Let's say you are building a new website to help people improve their tailgating parties when they attend sports games. You will provide the latest tailgating news, the ability to purchase tailgating supplies, and an extensive library of in-depth articles. As part of your site, tailgaters can find storage units based on proximity to stadiums so that they can easily store their tailgating supplies. In fact, they can even arrange to have items purchased through your site delivered directly to the storage facility. Facility owners can pay you to be listed on your website, "TailgatingTactics.net", and of course you would like to have up-to-date unit pricing and availability.
Mr. Sluggerrr has a facility, "Sluggerrr's Storage", located just down the street from Kauffman Stadium. Storage has been slow of late so he decides that being listed on TailgatingTactics.net would be just the thing. Conveniently, he is using storEDGE as his management software. He sets up a user on storEDGE and provides you the following information:
MNO
PQR
36HJ
When TailgatingTactics.net performs a request to retrieve the units list at Sluggerrr's Storage, the request will include the following information:
MNO
PQR
36HJ
Mrs. Wolf has two facilities, "Wolf's Storage" and "Wolf's Storage II", located just down the street from Arrowhead Stadium. Since these two stadiums are adjacent, Mrs. Wolf and Mr. Sluggerrr are intense competitors. When she notices Sluggerrr's Storage listed on TailgatingTactics.net, she decides that she must list both of her facilities as well. She sets up a user on storEDGE and provides you the following information:
MNO
PQR
78DN
69EJ
When TailgatingTactics.net performs a request to retrieve the units list at Wolf's Storage, the request will include the following information:
MNO
PQR
78DN
And for Wolf's Storage II:
MNO
PQR
69EJ
Notice that in all three examples, the access ID is the same because it corresponds to your application, TailgatingTactics.net. The facility ID is obviously specific to each facility. In the case of Mrs. Wolf, the access ID and secret are the same for both facilities because they are under the same company.
The storEDGE API sends and receives data in JSON format. For more info on JSON, check out http://json.org.
It is highly recommended that the standard Content-Type
and Accept
headers be included on every storEDGE API call. Since the format is JSON, the values of these headers should be application/json
. Some calls may not succeed without these headers.
Standard HTTP response codes are used as strictly as possible to indicate the status of a request. You can find a list of codes at http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html.
All response bodies return a meta
hash which indicates the parameters received, the request method, pagination details (if applicable), status code and message, etc. For example:
{
"meta": {
"message": "Invalid OAuth Request",
"status_code": 401,
"request_id": "ccfe50a7-268a-49e0-bc9b-1265d440bffe",
"error_code": 2,
"status_message": "Bad Request",
"status_cat": "http://httpcats.herokuapp.com/400",
"parameters": {
"path": "/"
},
"request_method": "GET"
}
}
If the response is an error, the meta
hash will include several useful keys:
error_code
indicating the particular error that has occurred so that you may check the response for specific errors if you need to.request_id
giving a unique ID to this request. This may be useful in corresponding with storEDGE regarding a particular request or error that you are having trouble with.The possible error codes are:
Code 1 - Api Error
HTTP status: Internal Server Error (500)
Description: Unknown API error. Sorry.
Code 2 - Authentication Failed
HTTP status: Unauthorized (401)
Description: Invalid OAuth Request
Code 3 - Action Failed
HTTP status: Bad Request (400)
Description: The requested action could not be performed.
Code 4 - Missing Or Invalid Parameter
HTTP status: Bad Request (400)
Description: At least one parameter was missing or did not match validation criteria.
Code 5 - Conflicting Parameters
HTTP status: Bad Request (400)
Description: The supplied parameters conflict with one another.
Code 6 - Cannot Change Reservation
HTTP status: Bad Request (400)
Description: Reservations cannot be unreserved. Please close this lead and create a new one or contact the facility.
Code 7 - Tenant Access Denied
HTTP status: Bad Request (400)
Description: The requested action has been disabled for tenants. Please visit the facility for more information.
Code 8 - Invalid Login Or Password
HTTP status: Bad Request (400)
Description: The login and/or password provided was incorrect.
Code 9 - Resource Not Found
HTTP status: Not Found (404)
Description: The resource you requested could not be found.
Code 10 - Invalid Sort Parameter
HTTP status: Bad Request (400)
Description: Either the sort parameter you specified is not supported, or this resource does not support sorting.
Code 11 - Tenant Already Signed Up
HTTP status: Bad Request (400)
Description: The tenant account you are trying to register already has an account setup.
Code 12 - Refund Already Voided
HTTP status: Bad Request (400)
Description: The refund requested has already been voided
Code 13 - Unauthorized Access
HTTP status: Forbidden (403)
Description: The client does not have access rights to the requested content.
Some client technologies do not gracefully handle HTTP status codes that are not 200 (OK) or 500 (Internal server error). While not recommended, you can force the HTTP status code to always be 200 (OK). The meta
data that is returned on every response body will still contain the true status code in the status_code
field. To use this option on a call without a request body, you can pass in the suppress_response_codes=true
query parameter on the URL. On a call with a request body (such as a POST), you can add this parameter directly into the body, like so:
{
"suppress_response_codes": true,
"lead": {
"is_reservation": false,
...
}
}
Any call that returns a collection can be limited using the per_page
and page
query parameters. For example:
https:///v1/c9ed5cc6eeb94f8594d23fc8c5162887/tenants?per_page=25&page=2
Any request that supports pagination will include information about it in the response. By default responses are limited to 100 items.
"meta": {
"pagination": {
"current_page": 1,
"total_pages": 1,
"per_page": 100,
"total_entries": 4,
"previous_page": null,
"next_page": null
},
"status_code": 200,
"status_message": "OK",
"status_cat": "http://httpcats.herokuapp.com/200",
"parameters": {
"facility_id": "622c5ea6-a85a-4579-8e5f-484d8c97eccc"
},
"request_method": "GET"
}
Some calls that return a collection can be sorted using the sort
query parameter. Multiple sorting criteria can be specified with a comma. The sort order can be changed by prepending the sort parameter with either a +
or -
.
A valid list of sort options can be found on the page for each resource.
In some cases the response returned from the API is gigantic and contains a lot of data you don't care about. In these cases, it is useful to specify which fields will be returned for a given type of object. This roughly mirrors the JSON API spec at http://jsonapi.org/format/#fetching-sparse-fieldsets.
When you specify which fields are to be returned, only those fields are returned. This applies to associations and nested objects as well.
Generally the name of the object is the singularized name of the class.
Let's say you are loading ledgers
, which happens to include information about the ledger and also embeds the unit. Perhaps you'd only like to see a few of these data points:
https:///v1/c9ed5cc6eeb94f8594d23fc8c5162887/ledgers?fields[ledger]=current_rate,unit,id&fields[unit]=name,size,price
Any call that returns a collection can be limited using the created_after
and/or created_before
query parameters, which will cause only results created between given timestamps to be returned. You may supply one or both of these parameters. The parameter format is parsed using a series of heuristics so any reasonably-formatted timestamp should work, however, it is suggested that you use ISO 8601/RFC 3339 (http://www.ietf.org/rfc/rfc3339.txt). Many programming languages already have the ability to convert to this format.
https:///v1/c9ed5cc6eeb94f8594d23fc8c5162887/tenants?created_after=2014-07-15T10:37:25-05:00
https:///v1/c9ed5cc6eeb94f8594d23fc8c5162887/tenants?created_before=2014-07-15T10:37:25-05:00
https:///v1/c9ed5cc6eeb94f8594d23fc8c5162887/tenants?created_after=2014-07-15T10:37:25-05:00&created_before=2014-07-16T10:37:25-05:00
Any call that returns a collection can be limited using the updated_since
query parameter, which will cause only results changed since the given timestamp to be returned. The parameter format is parsed using a series of heuristics so any reasonably-formatted timestamp should work, however, it is suggested that you use ISO 8601/RFC 3339 (http://www.ietf.org/rfc/rfc3339.txt). Many programming languages already have the ability to convert to this format.
https:///v1/c9ed5cc6eeb94f8594d23fc8c5162887/tenants?updated_since=2014-07-15T10:37:25-05:00
Any call that returns a collection can be limited using the only_ids
query parameter, which will cause only the specified records to be returned. The parameter should be a comma-separated list of IDs. This is useful if you already know the IDs of the records you want.
https:///v1/c9ed5cc6eeb94f8594d23fc8c5162887/tenants?only_ids=622c5ea6-a85a-4579-8e5f-484d8c97eccc,ccfe50a7-268a-49e0-bc9b-1265d440bffe
The storEDGE API inherently returns robust JSON structures. This is intended to make the consumer’s job easier, so that most (if not all) of the information you need is returned from the original call, rather than having to make a series of subsequent calls with associated ID’s.
For example, the GET /units
call will return the amenities and unit type for each unit in the facility:
{
"units": [
{
"id": "d41d99ec913b41f387564717f0ef265f",
...
"unit_amenities": [
{
"id": "ffadbe8ccee841fba4534563f239cda0",
"name": "Heated"
},
{
"id": "fd41eeb0aae840f4a6c0e97bc8544e8d",
"name": "Stacked Space"
},
],
"unit_type": {
"id": "fc8828e4ae1d41f584bb28d27d4c7a2f",
"name": "Parking Space"
}
},
{
"id": "244388eaa18a4dc5bbee61f02f4521a1",
...
"unit_amenities": [
{
"id": "ffadbe8ccee841fba4534563f239cda0",
"name": "Heated"
},
{
"id": "fd41eeb0aae840f4a6c0e97bc8544e8d",
"name": "Stacked Space"
},
],
"unit_type": {
"id": "fc8828e4ae1d41f584bb28d27d4c7a2f",
"name": "Parking Space"
}
}
]
}
While this is convenient if the consumer’s intention is to retrieve one or two units, this data becomes quite redundant if applied to tens or hundreds of units. The overhead of this data may no longer be worth the cost of the convenience. Sideloading is a tool consumers can use to address this issue.
On a GET call, passing the sideload=true
query parameter on the URL will restructure the data so that the common elements are extracted from each struct’s body and listed in a separate, named section of the response. Applying this strategy to the example above yields the following:
{
"unit_amenities": {
"ffadbe8ccee841fba4534563f239cda0": {
"id": "ffadbe8ccee841fba4534563f239cda0",
"name": "Heated"
},
"90ebf9fe19fc48dfa71df9a47aba291e": {
"id": "90ebf9fe19fc48dfa71df9a47aba291e",
"name": "Air Cooled"
},
"fd41eeb0aae840f4a6c0e97bc8544e8d": {
"id": "fd41eeb0aae840f4a6c0e97bc8544e8d",
"name": "Stacked Space"
}
...
},
"unit_types": {
...
"fc8828e4ae1d41f584bb28d27d4c7a2f": {
"id": "fc8828e4ae1d41f584bb28d27d4c7a2f",
"name": "Parking Space"
}
},
"units": [
{
"id": "d41d99ec913b41f387564717f0ef265f",
...
"unit_amenity_ids": [
"ffadbe8ccee841fba4534563f239cda0",
"90ebf9fe19fc48dfa71df9a47aba291e",
"fd41eeb0aae840f4a6c0e97bc8544e8d"
],
"unit_type_id": "fc8828e4ae1d41f584bb28d27d4c7a2f"
},
{
"id": "244388eaa18a4dc5bbee61f02f4521a1",
...
"unit_amenity_ids": [
"ffadbe8ccee841fba4534563f239cda0",
"90ebf9fe19fc48dfa71df9a47aba291e",
"fd41eeb0aae840f4a6c0e97bc8544e8d"
],
"unit_type_id": "fc8828e4ae1d41f584bb28d27d4c7a2f"
}
]
}
On a call with a request body (such as a POST), you can add this parameter directly into the body, like so:
{
"sideload": true,
"lead": {
"is_reservation": false,
...
}
}
Depending on what you're doing with the API, sometimes you might want more or less associated data returned with the response. For example, when fetching tenants, you might simply want a list of the current ledger IDs for tenants. Or you instead may wish to receive the ledger object included in the request directly. We have tried to choose sensible defaults for every association, but you can choose to override them.
You can pass the include_as_object
parameter with a list of associations to include the entire object. The list should be comma-separated, like so include_as_object=facility,phone_numbers,mailing_address
. Note that this option has no effect when sideload=true
is specified, because by definition sideloading includes the associated object ID in the record.
You can pass the include_as_id
parameter with a list of associations to include just the ID. The list should be comma-separated, like so include_as_id=facility,phone_numbers,mailing_address
.
Resource | Description |
---|---|
POST /v1/:facility_id/tenants/:tenant_id/attachments | Create (Upload) a file/attachment for an associated tenant |
Resource | Description |
---|---|
GET /v1/:facility_id/auctions/scheduled | Shows all scheduled auctions |
Resource | Description |
---|---|
GET /v1/companies/:company_id/leads | Show all leads |
GET /v1/companies/:company_id/leads/current | Show all current leads |
GET /v1/companies/:company_id/leads/follow_up | Show all followup leads |
GET /v1/companies/:company_id/leads/reservations | Show all leads that are reservations |
GET /v1/companies/:company_id/leads/inquiries | Show all leads that are not reservations (inquiries) |
GET /v1/companies/:company_id/leads/missed_move_ins | Show all missed move ins |
GET /v1/companies/:company_id/leads/waitlist | Show all waitlist leads |
GET /v1/companies/:company_id/leads/open/events | Shows all lead events for open leads |
GET /v1/companies/:company_id/leads/counts | Shows a count of open leads by status (lead, reservation) |
GET /v1/companies/:company_id/leads/:id | Show a particular lead |
Resource | Description |
---|---|
GET /v1/:facility_id/discount_plans | Show configured discount plans |
GET /v1/:facility_id/discount_plans/:id | Show a particular discount plan |
Resource | Description |
---|---|
GET /v1/:facility_id/documents/:id | Returns a pdf of the specified document |
GET /v1/:facility_id/documents/:session_document_id/session/:session_id | Returns a pdf of the specifed document for a move in |
GET /v1/:facility_id/events/:event_id/documents | Returns a list of documents and their IDs |
POST /v1/:facility_id/documents/:event_id/send_esignable_documents | Send esignable documents for a given event via email or sms to a specifed email address or phone number |
Resource | Description |
---|---|
POST /v1/:facility_id/events/:event_id/esign | Get esign docs from given Facility and MoveInEvent |
Resource | Description |
---|---|
POST /v1/:facility_id/gate_activities | Log a Gate Activity |
Resource | Description |
---|---|
POST /v1/:facility_id/gate_codes/availability_check | Check gate code availability |
GET /v1/:facility_id/access_points | Provides a list of cloud access points for a facility |
POST /v1/:facility_id/gate_codes/open | Opens a gate |
Resource | Description |
---|---|
GET /v1/:facility_id/insurance/summary | A summary of insurance information for the facility |
GET /v1/:facility_id/insurance/activity | A detailed list of insurance activity for the facility |
PUT /v1/:facility_id/insurance/tenant_auto_enroll_settings | Send a list of tenant IDs that should be excluded from automatically being enrolled in Facility Insurance; or included back into auto enrollment |
Resource | Description |
---|---|
GET /v1/:facility_id/invoiceable_items | Show all invoiceable items |
GET /v1/:facility_id/invoiceable_items/insurance | Show all insurance items |
GET /v1/:facility_id/invoiceable_items/services | Show all services |
GET /v1/:facility_id/invoiceable_items/retail | Show all retail items |
POST /v1/:facility_id/invoiceable_items/retail_payment | Make a payment on a retail item |
GET /v1/:facility_id/invoiceable_items/fees | Show all fees |
GET /v1/:facility_id/invoiceable_items/rental_center | Show all retail items that are eligible to be sold in Rental Center |
Resource | Description |
---|---|
GET /v1/:facility_id/invoices/:id | Show a particular invoice |
GET /v1/:facility_id/invoices/:invoice_id/pdf | Show a particular invoice pdf |
Resource | Description |
---|---|
GET /v1/:facility_id/leads | Show all leads |
GET /v1/:facility_id/leads/current | Show all current leads |
GET /v1/:facility_id/leads/follow_up | Show all followup leads |
GET /v1/:facility_id/leads/reservations | Show all leads that are reservations |
GET /v1/:facility_id/leads/inquiries | Show all leads that are not reservations (inquiries) |
GET /v1/:facility_id/leads/missed_move_ins | Show all missed move ins |
GET /v1/:facility_id/leads/waitlist | Show all waitlist leads |
GET /v1/:facility_id/leads/open/events | Shows all lead events for open leads |
GET /v1/:facility_id/leads/counts | Shows a count of open leads by status (lead, reservation) |
GET /v1/:facility_id/leads/:id | Show a particular lead |
POST /v1/:facility_id/leads | Create a new lead |
PATCH /v1/:facility_id/leads/:id | Update an existing lead |
PUT /v1/:facility_id/leads/:id | Update an existing lead |
DELETE /v1/:facility_id/leads/:id | Destroy a lead |
Resource | Description |
---|---|
GET /v1/:facility_id/ledgers/:ledger_id/fees | Returns a list of fee line items charged to a ledger |
POST /v1/:facility_id/ledgers/:ledger_id/add_fee | Add a fee to a ledger |
POST /v1/:facility_id/ledgers/:ledger_id/remove_fee | Removes a fee charged to a ledger |
Resource | Description |
---|---|
GET /v1/:facility_id/move_ins | Collection of all current move ins for the current facility that have not been completed or cancelled |
GET /v1/:facility_id/move_ins/:id | Returns a move in event |
POST /v1/:facility_id/move_ins/review_cost | Review the cost of moving into a unit |
POST /v1/:facility_id/move_ins/process_move_in | Moves a tenant into specified unit |
Resource | Description |
---|---|
POST /v1/:facility_id/tenants/:tenant_id/notes | Create a new note on a tenant or unit. |
POST /v1/:facility_id/notes | Create a new note on a tenant or unit. |
Resource | Description |
---|---|
GET /v1/:facility_id/payment_methods/credit_card_types | Types of credit cards accepted by the facility |
GET /v1/:facility_id/tenants/:tenant_id/payment_methods | Shows all payment methods for a tenant |
GET /v1/:facility_id/tenants/:tenant_id/payment_methods/:id | Shows a specific payment method for a tenant |
Resource | Description |
---|---|
PUT /v1/:facility_id/ledgers/:ledger_id/private_insurance | Create or update a ledger's private insurance information |
Resource | Description |
---|---|
GET /v1/:facility_id/rate_applied_actions | Fetch all rate applied actions completed on or between a start and end date |
Resource | Description |
---|---|
GET /v1/:facility_id/smses | Shows all smses |
Resource | Description |
---|---|
GET /v1/:facility_id/tenants/:tenant_id/leads | Show all leads |
GET /v1/:facility_id/tenants/:tenant_id/leads/current | Show all current leads |
GET /v1/:facility_id/tenants/:tenant_id/leads/follow_up | Show all followup leads |
GET /v1/:facility_id/tenants/:tenant_id/leads/reservations | Show all leads that are reservations |
GET /v1/:facility_id/tenants/:tenant_id/leads/inquiries | Show all leads that are not reservations (inquiries) |
GET /v1/:facility_id/tenants/:tenant_id/leads/missed_move_ins | Show all missed move ins |
GET /v1/:facility_id/tenants/:tenant_id/leads/waitlist | Show all waitlist leads |
GET /v1/:facility_id/tenants/:tenant_id/leads/open/events | Shows all lead events for open leads |
GET /v1/:facility_id/tenants/:tenant_id/leads/counts | Shows a count of open leads by status (lead, reservation) |
GET /v1/:facility_id/tenants/:tenant_id/leads/:id | Show a particular lead |
Resource | Description |
---|---|
GET /v1/:facility_id/tenant_portal_settings | Shows all tenant portal settings |
Resource | Description |
---|---|
GET /v1/companies/:company_id/tiers | Show all tiers for a company |
GET /v1/companies/:company_id/tiers/:id | Gets a single tier |
POST /v1/companies/:company_id/tiers | Creates a single tier |
PATCH /v1/companies/:company_id/tiers/:id | Updates a single tier |
PUT /v1/companies/:company_id/tiers/:id | Updates a single tier |
DELETE /v1/companies/:company_id/tiers/:id | Deletes a tier and reranks the remaining tiers |
PATCH /v1/companies/:company_id/tiers/reorder | Updates the rank of each active tier in the company |
Resource | Description |
---|---|
PUT /v1/:facility_id/unit_group_tier_rates/update | Updates or creates one or many unit group tier rates |
GET /v1/:facility_id/unit_group_tier_rates | Show all unit group tier rates for a facility |
Resource | Description |
---|---|
GET /v1/:facility_id/unit_groups | Shows all unit groups |
GET /v1/:facility_id/unit_groups/:id | Shows a unit group by id |
POST /v1/:facility_id/unit_groups | Create one or more new units groups. |
PATCH /v1/:facility_id/unit_groups | Update one or more unit groups. |
DELETE /v1/:facility_id/unit_groups | Destroy one or more unit groups |
GET /v1/:facility_id/unit_groups/:unit_group_id/units | Shows a unit group's units |
GET /v1/:facility_id/unit_groups/:unit_group_id/review_cost | Review the cost of a unit group with discount plans applied |
Resource | Description |
---|---|
GET /v1/:facility_id/unit_types | Lists all unit types |
GET /v1/:facility_id/unit_types/:id | Show a particular unit type |
Resource | Description |
---|---|
GET /v1/:facility_id/units | Shows all units |
GET /v1/:facility_id/units/:id | Show a particular unit |
GET /v1/:facility_id/units/available | Shows all units that are available for move in |
PATCH /v1/:facility_id/units/:id | Update a unit |
PUT /v1/:facility_id/units/:id | Update a unit |
PUT /v1/:facility_id/units/bulk_update | Update one or more units |
POST /v1/:facility_id/units | Create one or more new units within the same group. |
POST /v1/:facility_id/units/bulk_create | Create one or more new units belonging to any unit groups. |
GET /v1/:facility_id/units/rate_history | Shows the detailed change history of all rate types for unit(s) |
GET /v1/:facility_id/units/:unit_id/future_scheduled_rates | Future scheduled rate changes for currently or previously occupied units. |
Resource | Description |
---|---|
POST /v1/:facility_id/web_payments/create_transport_key | Create a transport key for a web payment |
POST /v1/:facility_id/web_payments/cancel_transport_key | Used for when a user cancels the payment or the payment does not process successfully. |