api

package
v1.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 4, 2018 License: MIT Imports: 31 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewJoinServerAPI

func NewJoinServerAPI() http.Handler

NewJoinServerAPI create a new JoinServerAPI.

Types

type ApplicationAPI

type ApplicationAPI struct {
	// contains filtered or unexported fields
}

ApplicationAPI exports the Application related functions.

func NewApplicationAPI

func NewApplicationAPI(validator auth.Validator) *ApplicationAPI

NewApplicationAPI creates a new ApplicationAPI.

func (*ApplicationAPI) Create

Create creates the given application.

func (*ApplicationAPI) CreateHTTPIntegration

func (a *ApplicationAPI) CreateHTTPIntegration(ctx context.Context, in *pb.HTTPIntegration) (*pb.EmptyResponse, error)

CreateHTTPIntegration creates an HTTP application-integration.

func (*ApplicationAPI) CreateInfluxDBIntegration

func (a *ApplicationAPI) CreateInfluxDBIntegration(ctx context.Context, in *pb.CreateInfluxDBIntegrationRequest) (*pb.EmptyResponse, error)

CreateInfluxDBIntegration create an InfluxDB application-integration.

func (*ApplicationAPI) Delete

Delete deletes the given application.

func (*ApplicationAPI) DeleteHTTPIntegration

func (a *ApplicationAPI) DeleteHTTPIntegration(ctx context.Context, in *pb.DeleteHTTPIntegrationRequest) (*pb.EmptyResponse, error)

DeleteHTTPIntegration deletes the application-integration of the given type.

func (*ApplicationAPI) DeleteInfluxDBIntegration

func (a *ApplicationAPI) DeleteInfluxDBIntegration(ctx context.Context, in *pb.DeleteInfluxDBIntegrationRequest) (*pb.EmptyResponse, error)

DeleteInfluxDBIntegration deletes the InfluxDB application-integration.

func (*ApplicationAPI) Get

Get returns the requested application.

func (*ApplicationAPI) GetHTTPIntegration

func (a *ApplicationAPI) GetHTTPIntegration(ctx context.Context, in *pb.GetHTTPIntegrationRequest) (*pb.HTTPIntegration, error)

GetHTTPIntegration returns the HTTP application-itegration.

func (*ApplicationAPI) GetInfluxDBIntegration

GetInfluxDBIntegration returns the InfluxDB application-integration.

func (*ApplicationAPI) List

List lists the available applications.

func (*ApplicationAPI) ListIntegrations

ListIntegrations lists all configured integrations.

func (*ApplicationAPI) Update

Update updates the given application.

func (*ApplicationAPI) UpdateHTTPIntegration

func (a *ApplicationAPI) UpdateHTTPIntegration(ctx context.Context, in *pb.HTTPIntegration) (*pb.EmptyResponse, error)

UpdateHTTPIntegration updates the HTTP application-integration.

func (*ApplicationAPI) UpdateInfluxDBIntegration

func (a *ApplicationAPI) UpdateInfluxDBIntegration(ctx context.Context, in *pb.UpdateInfluxDBIntegrationRequest) (*pb.EmptyResponse, error)

UpdateInfluxDBIntegration updates the InfluxDB application-integration.

type ApplicationServerAPI

type ApplicationServerAPI struct {
}

ApplicationServerAPI implements the as.ApplicationServerServer interface.

func NewApplicationServerAPI

func NewApplicationServerAPI() *ApplicationServerAPI

NewApplicationServerAPI returns a new ApplicationServerAPI.

func (*ApplicationServerAPI) HandleDownlinkACK

HandleDownlinkACK handles an ack on a downlink transmission.

func (*ApplicationServerAPI) HandleError

HandleError handles an incoming error.

HandleProprietaryUplink handles proprietary uplink payloads.

func (*ApplicationServerAPI) HandleUplinkData

HandleUplinkData handles incoming (uplink) data.

type DeviceAPI

type DeviceAPI struct {
	// contains filtered or unexported fields
}

DeviceAPI exports the Node related functions.

func NewDeviceAPI

func NewDeviceAPI(validator auth.Validator) *DeviceAPI

NewDeviceAPI creates a new NodeAPI.

func (*DeviceAPI) Activate

Activate activates the node (ABP only).

func (*DeviceAPI) Create

Create creates the given device.

func (*DeviceAPI) CreateKeys

CreateKeys creates the given device-keys.

func (*DeviceAPI) Delete

Delete deletes the node matching the given name.

func (*DeviceAPI) DeleteKeys

DeleteKeys deletes the device-keys for the given DevEUI.

func (*DeviceAPI) Get

Get returns the device matching the given DevEUI.

func (*DeviceAPI) GetActivation

GetActivation returns the device activation for the given DevEUI.

func (*DeviceAPI) GetKeys

GetKeys returns the device-keys for the given DevEUI.

func (*DeviceAPI) GetRandomDevAddr

GetRandomDevAddr returns a random DevAddr taking the NwkID prefix into account.

func (*DeviceAPI) ListByApplicationID

ListByApplicationID lists the devices by the given application ID, sorted by the name of the device.

func (*DeviceAPI) StreamEventLogs

StreamEventLogs stream the device events (uplink payloads, ACKs, joins, errors). Note: this endpoint is intended for debugging and should not be used for building integrations.

func (*DeviceAPI) StreamFrameLogs

StreamFrameLogs streams the uplink and downlink frame-logs for the given DevEUI. Note: these are the raw LoRaWAN frames and this endpoint is intended for debugging.

func (*DeviceAPI) Update

Update updates the device matching the given DevEUI.

func (*DeviceAPI) UpdateKeys

UpdateKeys updates the device-keys.

type DeviceProfileServiceAPI

type DeviceProfileServiceAPI struct {
	// contains filtered or unexported fields
}

DeviceProfileServiceAPI exports the ServiceProfile related functions.

func NewDeviceProfileServiceAPI

func NewDeviceProfileServiceAPI(validator auth.Validator) *DeviceProfileServiceAPI

NewDeviceProfileServiceAPI creates a new DeviceProfileServiceAPI.

func (*DeviceProfileServiceAPI) Create

Create creates the given device-profile.

func (*DeviceProfileServiceAPI) Delete

Delete deletes the device-profile matching the given id.

func (*DeviceProfileServiceAPI) Get

Get returns the device-profile matching the given id.

func (*DeviceProfileServiceAPI) List

List lists the available device-profiles.

func (*DeviceProfileServiceAPI) Update

Update updates the given device-profile.

type DeviceQueueAPI

type DeviceQueueAPI struct {
	// contains filtered or unexported fields
}

DeviceQueueAPI exposes the downlink queue methods.

func NewDeviceQueueAPI

func NewDeviceQueueAPI(validator auth.Validator) *DeviceQueueAPI

NewDeviceQueueAPI creates a new DeviceQueueAPI.

func (*DeviceQueueAPI) Enqueue

Enqueue adds the given item to the device-queue.

func (*DeviceQueueAPI) Flush

Flush flushes the downlink device-queue.

func (*DeviceQueueAPI) List

List lists the items in the device-queue.

type GatewayAPI

type GatewayAPI struct {
	// contains filtered or unexported fields
}

GatewayAPI exports the Gateway related functions.

func NewGatewayAPI

func NewGatewayAPI(validator auth.Validator) *GatewayAPI

NewGatewayAPI creates a new GatewayAPI.

func (*GatewayAPI) Create

Create creates the given gateway.

func (*GatewayAPI) Delete

Delete deletes the gateway matching the given ID.

func (*GatewayAPI) Get

Get returns the gateway matching the given Mac.

func (*GatewayAPI) GetLastPing

GetLastPing returns the last emitted ping and gateways receiving this ping.

func (*GatewayAPI) GetStats

GetStats gets the gateway statistics for the gateway with the given Mac.

func (*GatewayAPI) List

List lists the gateways.

func (*GatewayAPI) StreamFrameLogs

StreamFrameLogs streams the uplink and downlink frame-logs for the given mac. Note: these are the raw LoRaWAN frames and this endpoint is intended for debugging.

func (*GatewayAPI) Update

Update updates the given gateway.

type GatewayProfileAPI

type GatewayProfileAPI struct {
	// contains filtered or unexported fields
}

GatewayProfileAPI exports the GatewayProfile related functions.

func NewGatewayProfileAPI

func NewGatewayProfileAPI(validator auth.Validator) *GatewayProfileAPI

NewGatewayProfileAPI creates a new GatewayProfileAPI.

func (*GatewayProfileAPI) Create

Create creates the given gateway-profile.

func (*GatewayProfileAPI) Delete

Delete deletes the gateway-profile matching the given id.

func (*GatewayProfileAPI) Get

Get returns the gateway-profile matching the given id.

func (*GatewayProfileAPI) List

List returns the existing gateway-profiles.

func (*GatewayProfileAPI) Update

Update updates the given gateway-profile.

type InternalUserAPI

type InternalUserAPI struct {
	// contains filtered or unexported fields
}

InternalUserAPI exports the internal User related functions.

func NewInternalUserAPI

func NewInternalUserAPI(validator auth.Validator) *InternalUserAPI

NewInternalUserAPI creates a new InternalUserAPI.

func (*InternalUserAPI) Branding

Branding returns UI branding.

func (*InternalUserAPI) GlobalSearch

GlobalSearch performs a global search.

func (*InternalUserAPI) Login

Login validates the login request and returns a JWT token.

func (*InternalUserAPI) Profile

Profile returns the user profile.

type JoinServerAPI

type JoinServerAPI struct{}

JoinServerAPI implements the join-server API as documented in the LoRaWAN backend interfaces specification.

func (*JoinServerAPI) ServeHTTP

func (a *JoinServerAPI) ServeHTTP(w http.ResponseWriter, r *http.Request)

ServeHTTP implements the http.Handler interface.

type NetworkServerAPI

type NetworkServerAPI struct {
	// contains filtered or unexported fields
}

NetworkServerAPI exports the NetworkServer related functions.

func NewNetworkServerAPI

func NewNetworkServerAPI(validator auth.Validator) *NetworkServerAPI

NewNetworkServerAPI creates a new NetworkServerAPI.

func (*NetworkServerAPI) Create

Create creates the given network-server.

func (*NetworkServerAPI) Delete

Delete deletes the network-server matching the given id.

func (*NetworkServerAPI) Get

Get returns the network-server matching the given id.

func (*NetworkServerAPI) List

List lists the available network-servers.

func (*NetworkServerAPI) Update

Update updates the given network-server.

type OrganizationAPI

type OrganizationAPI struct {
	// contains filtered or unexported fields
}

OrganizationAPI exports the organization related functions.

func NewOrganizationAPI

func NewOrganizationAPI(validator auth.Validator) *OrganizationAPI

NewOrganizationAPI creates a new OrganizationAPI.

func (*OrganizationAPI) AddUser

Create creates the given organization-user link.

func (*OrganizationAPI) Create

Create creates the given organization.

func (*OrganizationAPI) Delete

Delete deletes the organization matching the given ID.

func (*OrganizationAPI) DeleteUser

Delete deletes the given user from the organization.

func (*OrganizationAPI) Get

Get returns the organization matching the given ID.

func (*OrganizationAPI) GetUser

GetUser returns the user details for the given user ID.

func (*OrganizationAPI) List

List lists the organizations to which the user has access.

func (*OrganizationAPI) Update

Update updates the given organization.

func (*OrganizationAPI) UpdateUser

Update updates the given user.

type ServiceProfileServiceAPI

type ServiceProfileServiceAPI struct {
	// contains filtered or unexported fields
}

ServiceProfileServiceAPI export the ServiceProfile related functions.

func NewServiceProfileServiceAPI

func NewServiceProfileServiceAPI(validator auth.Validator) *ServiceProfileServiceAPI

NewServiceProfileServiceAPI creates a new ServiceProfileServiceAPI.

func (*ServiceProfileServiceAPI) Create

Create creates the given service-profile.

func (*ServiceProfileServiceAPI) Delete

Delete deletes the service-profile matching the given id.

func (*ServiceProfileServiceAPI) Get

Get returns the service-profile matching the given id.

func (*ServiceProfileServiceAPI) List

List lists the available service-profiles.

func (*ServiceProfileServiceAPI) Update

Update updates the given serviceprofile.

type UserAPI

type UserAPI struct {
	// contains filtered or unexported fields
}

UserAPI exports the User related functions.

func NewUserAPI

func NewUserAPI(validator auth.Validator) *UserAPI

NewUserAPI creates a new UserAPI.

func (*UserAPI) Create

func (a *UserAPI) Create(ctx context.Context, req *pb.AddUserRequest) (*pb.AddUserResponse, error)

Create creates the given user.

func (*UserAPI) Delete

func (a *UserAPI) Delete(ctx context.Context, req *pb.UserRequest) (*pb.UserEmptyResponse, error)

Delete deletes the user matching the given ID.

func (*UserAPI) Get

func (a *UserAPI) Get(ctx context.Context, req *pb.UserRequest) (*pb.GetUserResponse, error)

Get returns the user matching the given ID.

func (*UserAPI) List

List lists the users.

func (*UserAPI) Update

Update updates the given user.

func (*UserAPI) UpdatePassword

func (a *UserAPI) UpdatePassword(ctx context.Context, req *pb.UpdateUserPasswordRequest) (*pb.UserEmptyResponse, error)

UpdatePassword updates the password for the user matching the given ID.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL