markers

package
v0.17.3 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2024 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// BasePath is the base path for serving the markers API, minus the 'api' prefix
	BasePath = "/v1/markers"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Module

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

func New

func New(processor *processing.Processor) *Module

func (*Module) MarkersGETHandler

func (m *Module) MarkersGETHandler(c *gin.Context)

MarkersGETHandler swagger:operation GET /api/v1/markers markersGet

Get timeline markers by name

---
tags:
- markers

produces:
- application/json

parameters:
-
	name: timeline
	type: array
	items:
		type: string
		enum:
			- home
			- notifications
	description: Timelines to retrieve.
	in: query

security:
- OAuth2 Bearer:
	- read:statuses

responses:
	'200':
		description: Requested markers
		schema:
			"$ref": "#/definitions/markers"
	'400':
		description: bad request
	'401':
		description: unauthorized
	'500':
		description: internal server error

func (*Module) MarkersPOSTHandler

func (m *Module) MarkersPOSTHandler(c *gin.Context)

MarkersPOSTHandler swagger:operation POST /api/v1/markers markersPost

Update timeline markers by name

---
tags:
- markers

consumes:
- multipart/form-data

produces:
- application/json

parameters:
-
	name: home[last_read_id]
	type: string
	description: Last status ID read on the home timeline.
	in: formData
-
	name: notifications[last_read_id]
	type: string
	description: Last notification ID read on the notifications timeline.
	in: formData

security:
- OAuth2 Bearer:
	- write:statuses

responses:
	'200':
		description: Requested markers
		schema:
			"$ref": "#/definitions/markers"
	'400':
		description: bad request
	'401':
		description: unauthorized
	'409':
		description: conflict (when two clients try to update the same timeline at the same time)
	'500':
		description: internal server error

func (*Module) Route

func (m *Module) Route(attachHandler func(method string, path string, f ...gin.HandlerFunc) gin.IRoutes)

Jump to

Keyboard shortcuts

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