appstore

package
v0.0.0-...-dfb39b5 Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	// ListPage calls GET /v1/connections?page=N&limit=M — returns one page of lightweight summaries, no config blobs.
	ListPage(ctx context.Context, page, limit int) ([]ConnectionSummary, error)

	// GetConnection calls GET /v1/connections/{id}/config — returns the full connection with all config blobs.
	GetConnection(ctx context.Context, id string) (*Connection, error)
}

Client abstracts communication with the appstore middleware.

func New

func New(url, apiKey string) Client

New returns an HTTPClient. Returns nil when url is empty (disables catalog integration).

type Connection

type Connection struct {
	ID         string      `json:"id"`
	Handle     string      `json:"handle"`
	Status     string      `json:"status"`
	Meta       Meta        `json:"meta"`
	Service    interface{} `json:"service"`
	Operations interface{} `json:"operations"`
	Resources  interface{} `json:"resources"`
}

Connection is returned by GET /v1/connections/{id}/config — full, with config blobs.

type ConnectionSummary

type ConnectionSummary struct {
	ID          string             `json:"id"`
	Handle      string             `json:"handle"`
	Status      string             `json:"status"`
	Short       string             `json:"short"`
	Description string             `json:"description,omitempty"`
	Operations  []OperationSummary `json:"operations"`
	Resources   []ResourceSummary  `json:"resources,omitempty"`
	Triggers    []TriggerSummary   `json:"triggers,omitempty"`
}

ConnectionSummary is returned by GET /v1/connections — lightweight, no config blobs.

type HTTPClient

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

func (*HTTPClient) GetConnection

func (c *HTTPClient) GetConnection(ctx context.Context, id string) (*Connection, error)

func (*HTTPClient) ListPage

func (c *HTTPClient) ListPage(ctx context.Context, page, limit int) ([]ConnectionSummary, error)

type Meta

type Meta struct {
	Short       string   `json:"short"`
	Description string   `json:"description,omitempty"`
	Icon        string   `json:"icon,omitempty"`
	Tags        []string `json:"tags,omitempty"`
}

type OperationSummary

type OperationSummary struct {
	Handle      string `json:"handle"`
	Short       string `json:"short"`
	Description string `json:"description,omitempty"`
}

type ResourceSummary

type ResourceSummary struct {
	Handle string `json:"handle"`
	Short  string `json:"short"`
}

type TriggerSummary

type TriggerSummary struct {
	Event       string `json:"event"`
	Resource    string `json:"resource"`
	Description string `json:"description,omitempty"`
}

Jump to

Keyboard shortcuts

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