endpoint

package
v0.0.0-...-0a18f65 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MakeCreateDocumentEndpoint

func MakeCreateDocumentEndpoint(svc watermark.Service) endpoint.Endpoint

func MakeFindEndpoint

func MakeFindEndpoint(svc watermark.Service) endpoint.Endpoint

func MakeServiceStatusEndpoint

func MakeServiceStatusEndpoint(svc watermark.Service) endpoint.Endpoint

func MakeStatusEndpoint

func MakeStatusEndpoint(svc watermark.Service) endpoint.Endpoint

func MakeWatermarkEndpoint

func MakeWatermarkEndpoint(svc watermark.Service) endpoint.Endpoint

Types

type CreateDocumentRequest

type CreateDocumentRequest struct {
	Document *internal.Document `json:"document"`
}

type CreateDocumentResponse

type CreateDocumentResponse struct {
	TicketID string `json:"ticket_id"`
	Err      string `json:"err,omitempty"`
}

type FindRequest

type FindRequest struct {
	Filters []internal.Filter `json:"filters,omitempty"`
}

type FindResponse

type FindResponse struct {
	Documents []internal.Document `json:"documents"`
	Err       string              `json:"err,omitempty"`
}

type ServiceStatusRequest

type ServiceStatusRequest struct{}

type ServiceStatusResponse

type ServiceStatusResponse struct {
	Code int    `json:"status"`
	Err  string `json:"err,omitempty"`
}

type Set

type Set struct {
	FindEndpoint           endpoint.Endpoint
	CreateDocumentEndpoint endpoint.Endpoint
	StatusEndpoint         endpoint.Endpoint
	ServiceStatusEndpoint  endpoint.Endpoint
	WatermarkEndpoint      endpoint.Endpoint
}

func NewEndpointSet

func NewEndpointSet(svc watermark.Service) Set

type StatusRequest

type StatusRequest struct {
	TicketID string `json:"ticket_id"`
}

type StatusResponse

type StatusResponse struct {
	Status internal.Status `json:"status"`
	Err    string          `json:"err,omitempty"`
}

type WatermarkRequest

type WatermarkRequest struct {
	TicketID string `json:"ticket_id"`
	Mark     string `json:"mark"`
}

type WatermarkResponse

type WatermarkResponse struct {
	Code int    `json:"code"`
	Err  string `json:"err"`
}

Jump to

Keyboard shortcuts

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