Packages

Erlang client library for the AT&T M2X (http://m2x.att.com) API. AT&T M2X is a cloud-based fully managed time-series data storage service for network connected machine-to-machine (M2M) devices and the Internet of Things (IoT).

Current section

Files

Jump to
m2x_erlang src m2x_collection.erl
Raw

src/m2x_collection.erl

-module(m2x_collection).
%% API
-export([view/2 ]).
-export([ update/3]).
-export([delete/2 ]).
%% @doc Get details of an existing collection.
%% https://m2x.att.com/developer/documentation/v2/collections#View-Collection-Details
view(Client, Coll) -> Client({get, <<"/collections/", Coll/binary>>}).
%% @doc Update an existing collection's information.
%% https://m2x.att.com/developer/documentation/v2/collections#Update-Collection-Details
update(Client, Coll, Params) -> Client({put, <<"/collections/", Coll/binary>>, Params}).
%% @doc Delete an existing device collection.
%% https://m2x.att.com/developer/documentation/v2/collections#Delete-Collection
delete(Client, Coll) -> Client({delete, <<"/collections/", Coll/binary>>}).