device

package
v0.0.0-...-4e1c0da Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Create

func Create(context *common.Context)

Create godoc

@Summary      Create or update device
@Id           createDevice
@Tags         Device
@Description  Create or update device information
@Param        user_secret  path      string       true   "Secret of user"
@Param        device_id    path      string       true   "device_id should be a valid UUID"
@Param        channel      formData  enum.Sender  true   "channel can be used."
@Param        device_name  formData  string       false  "device name"
@Param        device_meta  formData  string       false  "additional device meta"
@Param        token        formData  string       false  "channel token"
@Produce      json
@Success      200  {object}  common.Response[bool]
@Failure      400  {object}  common.BadRequestResponse
@Failure      401  {object}  common.UnauthorizedResponse
@Router       /{user_secret}/device/{device_id} [put]

func Delete

func Delete(context *common.Context)

Delete godoc

@Summary      Delete device
@Id           deleteDevice
@Tags         Device
@Description  Delete device with device_id
@Param        user_secret  path  string  true  "Secret of user"
@Param        device_id    path  string  true  "The identifier of device, should be a UUID"
@Produce      json
@Success      200  {object}  common.Response[bool]
@Router       /{user_secret}/device/{device_id} [delete]

Types

This section is empty.

Jump to

Keyboard shortcuts

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