jwplatform

package module
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2025 License: Apache-2.0 Imports: 7 Imported by: 0

README

Go JW Platform

GoDoc Build Status

The official Go client library for accessing the JW Platform API.

Requirements

Go 1.15+

Usage

import (
  "github.com/jwplayer/jwplatform-go"
  "github.com/jwplayer/jwplatform-go/media"
)

jwplatform := jwplatform.New("API_SECRET")
siteID := "9kzNUpe4"
mediaID := "LaJFzc9d"

// Get a Resource
media, err := jwplatform.Media.Get(siteID, mediaID)

// Create a Resource
mediaToCreate := &jwplatform.MediaMetadata(Title: "My new video")
media, err := jwplatform.Media.Create(siteID, mediaToCreate)

// List a Resource
mediaResources, err := jwplatform.Media.List(siteID, nil)
// Optionally include query parameters, including page, page length, sort, and filters.
params := jwplatform.QueryParams{Page: 2, PageLength: 5}
mediaResources, err := jwplatform.Media.List(siteID, params)

// Update a Resource
updateMetadata := &jwplatform.MediaMetadata{Title: "Updated video title"}
updatedMedia, err := jwplatform.Media.Update(siteID, mediaID, updateMetadata)

// Delete a Resource
_ := jwplatform.Media.Delete(siteID, mediaID)

Supported operations

All API methods documentated on the API are available in this client. Please refer to our api documentation.

Test

Before running the tests, make sure to grab all of the package's dependencies:

go get -t -v

Run all tests:

make test

For any requests, bug or comments, please [open an issue][issues] or [submit a pull request][pulls].

V1 Client

The V1 Client remains available for use, but is deprecated. We strongly recommend using the V2 Client. For documentation on the V1 Client, please refer to the v1 submodule.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AnalyticsClient

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

AnalyticsClient for interacting with V2 Analytics API.

func (*AnalyticsClient) Query

func (c *AnalyticsClient) Query(siteID string, queryParams *AnalyticsQueryParameters) (*AnalyticsResponse, error)

Query the Analytics API

type AnalyticsQueryParameters

type AnalyticsQueryParameters struct {
	Source string `url:"source"`
	Format string `url:"format"`
}

AnalyticsQueryParameters define the allowed parameters on the Query action.

type AnalyticsResponse

type AnalyticsResponse struct {
	Dimensions        []string       `json:"dimensions"`
	StartDate         string         `json:"start_date"`
	EndDate           string         `json:"end_date"`
	Filter            string         `json:"filter"`
	IncludeMetadata   bool           `json:"include_metadata"`
	Metrics           []reportMetric `json:"metrics"`
	Sort              []reportSort   `json:"sort"`
	Page              int            `json:"page"`
	PageLength        int            `json:"page_length"`
	RelativeTimeframe string         `json:"relative_timeframe"`
}

AnalyticsResponse is the structure returned via the Query action.

type BidSettingsMetadata

type BidSettingsMetadata struct {
	BidTimeout             int      `json:"bidTimeout"`
	FloorPriceCents        int      `json:"floorPriceCents"`
	MediationLayerAdServer string   `json:"mediationLayerAdServer"`
	Buckets                []Bucket `json:"buckets"`
}

BidSettingsMetadata represents the configuration for the player bidding plugin

type BiddersMetadata

type BiddersMetadata struct {
	Name         string            `json:"name"`
	ID           string            `json:"id"`
	PubID        string            `json:"pubid"`
	CustomParams map[string]string `json:"custom_params"`
}

BiddersMetadata describes a configured Player Bidding bidder

type BidsMetadata

type BidsMetadata struct {
	Settings BidSettingsMetadata `json:"settings"`
	Bidders  []BiddersMetadata   `json:"bidders"`
}

BidsMetadata represents the player bidding configuration as used by the JW Player

type Bucket

type Bucket struct {
	Min       float64 `json:"min"`
	Max       float64 `json:"max"`
	Increment float64 `json:"increment"`
}

Bucket represents a minimum, maximum value to which to apply an increment

type ChannelCreateMetadata

type ChannelCreateMetadata struct {
	CustomParams     map[string]string `json:"custom_params"`
	Dvr              string            `json:"dvr"`
	SimulcastTargets []simulcastTarget `json:"simulcast_targets"`
	Tags             []string          `json:"tags"`
	Title            string            `json:"title"`
	Latency          string            `json:"latency"`
	ReconnectWindow  int               `json:"reconnect_window"`
}

ChannelCreateMetadata describes the request structure used to create a Channel resource

type ChannelCreateRequest

type ChannelCreateRequest struct {
	Metadata ChannelCreateMetadata `json:"metadata"`
}

ChannelCreateRequest is the request structure required for Channel create calls.

type ChannelMetadata

type ChannelMetadata struct {
	CustomParams     map[string]string `json:"custom_params"`
	Dvr              string            `json:"dvr"`
	SimulcastTargets []simulcastTarget `json:"simulcast_targets"`
	Tags             []string          `json:"tags"`
	Title            string            `json:"title"`
}

ChannelMetadata describes a Channel resource

type ChannelResource

type ChannelResource struct {
	V2ResourceResponse

	Metadata        ChannelMetadata `json:"metadata"`
	Latency         string          `json:"latency"`
	RecentEvents    []recentEvent   `json:"recent_events"`
	ReconnectWindow int             `json:"reconnect_window"`
	Status          string          `json:"status"`
	StreamKey       string          `json:"stream_key"`
}

ChannelResource is the resource that is returned for all Channel resource requests

type ChannelResourcesResponse

type ChannelResourcesResponse struct {
	V2ResourcesResponse

	Channels []ChannelResource `json:"channels"`
}

ChannelResourcesResponse is the response structure for Channel list calls.

type ChannelUpdateRequest

type ChannelUpdateRequest struct {
	Metadata ChannelMetadata `json:"metadata"`
}

ChannelUpdateRequest is the request structure required for Channel update calls.

type ChannelsClient

type ChannelsClient struct {
	Events *EventsClient
	// contains filtered or unexported fields
}

ChannelsClient for interacting with V2 Channels and Channel Events API.

func NewChannelsClient

func NewChannelsClient(v2Client *V2Client) *ChannelsClient

NewChannelsClient returns a new Channels Client

func (*ChannelsClient) Create

func (c *ChannelsClient) Create(siteID string, ChannelCreateMetadata *ChannelCreateMetadata) (*ChannelResource, error)

Create a Channel resource.

func (*ChannelsClient) Delete

func (c *ChannelsClient) Delete(siteID, channelID string) error

Delete a Channel resource by ID.

func (*ChannelsClient) Get

func (c *ChannelsClient) Get(siteID, channelID string) (*ChannelResource, error)

Get a single Channel resource by ID.

func (*ChannelsClient) List

func (c *ChannelsClient) List(siteID string, queryParams *QueryParams) (*ChannelResourcesResponse, error)

List all Channel resources associated with a given Site ID.

func (*ChannelsClient) Update

func (c *ChannelsClient) Update(siteID, channelID string, channelMetadata *ChannelMetadata) (*ChannelResource, error)

Update a Channel resource by ID.

type CreateMediaRequest

type CreateMediaRequest struct {
	Metadata MediaMetadata `json:"metadata,omitempty"`
	Upload   Upload        `json:"upload,omitempty"`
}

CreateMediaRequest is the request structure required for Media create calls. By default, the 'direct' upload method is used.

type CreateMediaResponse

type CreateMediaResponse struct {
	V2ResourceResponse
	MediaResource
	UploadLink  string `json:"upload_link,omitempty"`
	UploadToken string `json:"upload_token,omitempty"`
	UploadID    string `json:"upload_id,omitempty"`
}

CreateMediaResponse is the response structure for Media create calls. If "direct" or "multipart" were selected as the upload method, the response includes additional data required to complete your upload.

For direct uploads, the UploadLink will return a pre-signed S3 Upload Link.

For multipart uploads, the UploadToken and UploadID will be returned, to be used in subsequent requests to the V2 Upload API.

type CreateWebhookResponse

type CreateWebhookResponse struct {
	V2ResourceResponse
	Metadata WebhookMetadata `json:"metadata"`
	Secret   string          `json:"secret"`
}

CreateWebhookResponse is the response structure for Webhook create calls.

The Secret is returned only on Create calls and can be used to authenticate incoming webhooks Please see the documentation for additional details: https://developer.jwplayer.com/jwplayer/docs/learn-about-webhooks#section-verify-the-authenticity-of-a-webhook

type DRMPoliciesClient

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

DRMPoliciesClient for interacting with V2 DRM Policies API.

func (*DRMPoliciesClient) Create

func (c *DRMPoliciesClient) Create(siteID string, DRMPolicyMetadata *DRMPolicyMetadata) (*DRMPolicyResource, error)

Create a DRMPolicy resource.

func (*DRMPoliciesClient) Delete

func (c *DRMPoliciesClient) Delete(siteID, drmPolicyID string) error

Delete a DRMPolicy resource by ID.

func (*DRMPoliciesClient) Get

func (c *DRMPoliciesClient) Get(siteID, drmPolicyID string) (*DRMPolicyResource, error)

Get a single DRMPolicy resource by ID.

func (*DRMPoliciesClient) List

func (c *DRMPoliciesClient) List(siteID string, queryParams *QueryParams) (*DRMPolicyResourcesResponse, error)

List all DRMPolicy resources.

func (*DRMPoliciesClient) Update

func (c *DRMPoliciesClient) Update(siteID, drmPolicyID string, DRMPolicyMetadata *DRMPolicyMetadata) (*DRMPolicyResource, error)

Update a DRMPolicy resource by ID.

type DRMPolicyMetadata

type DRMPolicyMetadata struct {
	Name                    string `json:"name"`
	MaxWidth                int    `json:"max_width"`
	WidevineSecurity        string `json:"widevine_security"`
	PlayreadySecurity       int    `json:"playready_security"`
	AllowOfflinePersistence bool   `json:"allow_offline_persistence"`
	DigitalOutputProtection string `json:"digital_output_protection"`
	LicenseDuration         int    `json:"license_duration"`
	PlaybackDuration        int    `json:"playback_duration"`
}

DRMPolicyMetadata describes a DRMPolicy resource

type DRMPolicyResource

type DRMPolicyResource struct {
	V2ResourceResponse
	Metadata DRMPolicyMetadata `json:"metadata"`
}

DRMPolicyResource is the resource that is returned for all DRM Policy resource requests

type DRMPolicyResourcesResponse

type DRMPolicyResourcesResponse struct {
	V2ResourcesResponse

	DRMPolicies []DRMPolicyResource `json:"drm_policies"`
}

DRMPolicyResourcesResponse is the response structure for DRMPolicy list calls.

type DRMPolicyWriteRequest

type DRMPolicyWriteRequest struct {
	Metadata DRMPolicyMetadata `json:"metadata"`
}

DRMPolicyWriteRequest is the request structure required for DRMPolicy create and update calls.

type EventResource

type EventResource struct {
	V2ResourceResponse
	MasterAccess masterAccess `json:"master_access"`
	MediaID      string       `json:"media_id"`
	Status       string       `json:"status"`
}

EventResource is the resource that is returned for all Event resource requests, with the exception of the Create action, which extends this struct with upload-related data.

type EventResourcesResponse

type EventResourcesResponse struct {
	V2ResourcesResponse
	Events []EventResource `json:"events"`
}

EventResourcesResponse is the response structure for Event list calls.

type EventsClient

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

EventsClient for interacting with V2 Events API.

func (*EventsClient) Get

func (c *EventsClient) Get(siteID, channelID, eventID string) (*EventResource, error)

Get a single Event resource by Channel and Event ID.

func (*EventsClient) List

func (c *EventsClient) List(siteID, channelID string, queryParams *QueryParams) (*EventResourcesResponse, error)

List all Event resources associated with a given Site and Channel ID.

func (*EventsClient) RequestMaster

func (c *EventsClient) RequestMaster(siteID, channelID, eventID string) error

RequestMaster reqyests the master asset resources associated with a given Site ID.

type ImportMetadata

type ImportMetadata struct {
	URL            string         `json:"url"`
	HostOnImport   bool           `json:"host_on_import"`
	Title          string         `json:"title,omitempty"`
	State          string         `json:"state"`
	Type           string         `json:"type"`
	Username       string         `json:"username,omitempty"`
	Tags           []string       `json:"tags"`
	IngestMetadata IngestMetadata `json:"ingest_metadata"`
	IngestTags     []string       `json:"ingest_tags"`
}

ImportMetadata describes the metadata for an Import resource

type ImportReadMetadata

type ImportReadMetadata struct {
	ImportMetadata
	Password string `json:"password"`
}

ImportReadMetadata describes the read structure of an Import resource metadata. This extends the base metadata, including an additional field, Password, which cannot be updated on a write call (update/create)

type ImportResource

type ImportResource struct {
	V2ResourceResponse

	Metadata           ImportReadMetadata `json:"metadata"`
	TotalItemsIngested int                `json:"total_items_ingested"`
	LastImport         string             `json:"last_import"`
}

ImportResource is the resource that is returned for all Import resource requests, with the exception of the Create action, which extends this struct with upload-related data.

type ImportResourcesResponse

type ImportResourcesResponse struct {
	V2ResourcesResponse
	Imports []ImportResource `json:"imports"`
}

ImportResourcesResponse is the response structure for Import list calls.

type ImportWriteRequest

type ImportWriteRequest struct {
	Metadata ImportMetadata `json:"metadata"`
}

ImportWriteRequest is the request structure required for Import create calls.

type ImportsClient

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

ImportsClient for interacting with V2 Imports API.

func (*ImportsClient) Create

func (c *ImportsClient) Create(siteID string, importMetadata *ImportMetadata) (*ImportResource, error)

Create a Import resource.

func (*ImportsClient) Delete

func (c *ImportsClient) Delete(siteID, importID string) error

Delete a Import resource by ID.

func (*ImportsClient) Get

func (c *ImportsClient) Get(siteID, importID string) (*ImportResource, error)

Get a single Import resource by ID.

func (*ImportsClient) List

func (c *ImportsClient) List(siteID string, queryParams *QueryParams) (*ImportResourcesResponse, error)

List all Import resources associated with a given Site ID.

func (*ImportsClient) Update

func (c *ImportsClient) Update(siteID, importID string, importMetadata *ImportMetadata) (*ImportResource, error)

Update a Import resource by ID.

type IngestMetadata

type IngestMetadata struct {
	Captions    bool `json:"captions"`
	Categories  bool `json:"categories"`
	Credits     bool `json:"credits"`
	Description bool `json:"description"`
	Keywords    bool `json:"keywords"`
	PublishDate bool `json:"publish_date"`
	Tags        bool `json:"tags"`
	Thumbnails  bool `json:"thumbnails"`
}

IngestMetadata describes which data will be captured in the import from the MRSS feed.

type JWError

type JWError struct {
	Code        string `json:"code"`
	Description string `json:"description"`
}

JWError represents a single error from the V2 Platform API.

type JWErrorResponse

type JWErrorResponse struct {
	Errors     []JWError `json:"errors"`
	StatusCode int
}

JWErrorResponse represents a V2 Platform error response.

func (*JWErrorResponse) Error

func (e *JWErrorResponse) Error() string

Error serializes the error object to JSON and returns it as a string.

type JWPlatform

type JWPlatform struct {
	Version       string
	Analytics     *AnalyticsClient
	Channels      *ChannelsClient
	DRMPolicies   *DRMPoliciesClient
	Imports       *ImportsClient
	Media         *MediaClient
	PlayerBidding *PlayerBiddingClient
	Webhooks      *WebhooksClient
}

JWPlatform client for interacting with JW Player V2 Platform APIs.

func New

func New(apiSecret string) *JWPlatform

New generates an authenticated client for interacting with JW Player V2 Platform APIs.

type MediaClient

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

MediaClient for interacting with V2 Media API.

func (*MediaClient) Create

func (c *MediaClient) Create(siteID string, createMediaRequest *CreateMediaRequest) (*CreateMediaResponse, error)

Create a Media resource.

func (*MediaClient) Delete

func (c *MediaClient) Delete(siteID, mediaID string) error

Delete a Media resource by ID.

func (*MediaClient) Get

func (c *MediaClient) Get(siteID, mediaID string) (*MediaResource, error)

Get a single Media resource by ID.

func (*MediaClient) List

func (c *MediaClient) List(siteID string, queryParams *QueryParams) (*MediaResourcesResponse, error)

List all Media resources associated with a given Site ID.

func (*MediaClient) Reupload

func (c *MediaClient) Reupload(siteID, mediaID string, upload *Upload) (*CreateMediaResponse, error)

Reupload a Media resource by ID.

func (*MediaClient) Update

func (c *MediaClient) Update(siteID, mediaID string, mediaMetadata *MediaMetadata) (*MediaResource, error)

Update a Media resource by ID.

type MediaMetadata

type MediaMetadata struct {
	Title            string            `json:"title,omitempty"`
	Description      string            `json:"description,omitempty"`
	Author           string            `json:"author,omitempty"`
	Permalink        string            `json:"permalink,omitempty"`
	Category         string            `json:"category,omitempty"`
	PublishStartDate string            `json:"publish_start_date,omitempty"`
	PublishEndDate   string            `json:"publish_end_date,omitempty"`
	Tags             []string          `json:"tags,omitempty"`
	CustomParams     map[string]string `json:"custom_params,omitempty"`
	ExternalID       string            `json:"external_id,omitempty"`
}

MediaMetadata describes a Media resource

type MediaResource

type MediaResource struct {
	V2ResourceResponse

	Duration     float64 `json:"duration"`
	ExternalID   string  `json:"external_id"`
	TrimInPoint  string  `json:"trim_in_point"`
	TrimOutPoint string  `json:"trim_out_point"`
	Status       string  `json:"status"`
	ErrorMessage string  `json:"error_message"`
	MimeType     string  `json:"mime_type"`
	MediaType    string  `json:"media_type"`
	HostingType  string  `json:"hosting_type"`
	SourceURL    string  `json:"source_url"`

	Metadata MediaMetadata `json:"metadata"`
}

MediaResource is the resource that is returned for all Media resource requests, with the exception of the Create action, which extends this struct with upload-related data.

type MediaResourcesResponse

type MediaResourcesResponse struct {
	V2ResourcesResponse
	Media []MediaResource `json:"media"`
}

MediaResourcesResponse is the response structure for Media list calls.

type PlayerBiddingClient

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

PlayerBiddingClient for interacting with V2 Player Bidding Configurations API.

func (*PlayerBiddingClient) Create

func (c *PlayerBiddingClient) Create(siteID string, PlayerBiddingConfigurationMetadata *PlayerBiddingConfigurationMetadata) (*PlayerBiddingConfigurationResource, error)

Create a Player Bidding Configuration resource.

func (*PlayerBiddingClient) Delete

func (c *PlayerBiddingClient) Delete(siteID, importID string) error

Delete a Player Bidding Configuration resource by ID.

func (*PlayerBiddingClient) Get

Get a single Player Bidding Configuration resource by ID.

func (*PlayerBiddingClient) List

List all Player Bidding Configuration resources associated with a given Site ID.

func (*PlayerBiddingClient) Update

func (c *PlayerBiddingClient) Update(siteID, importID string, PlayerBiddingConfigurationMetadata *PlayerBiddingConfigurationMetadata) (*PlayerBiddingConfigurationResource, error)

Update a Player Bidding Configuration resource by ID.

type PlayerBiddingConfigurationMetadata

type PlayerBiddingConfigurationMetadata struct {
	Bids BidsMetadata `json:"bids"`
}

PlayerBiddingConfigurationMetadata describes the metadata for an Player Bidding Configuration resource

type PlayerBiddingConfigurationResource

type PlayerBiddingConfigurationResource struct {
	V2ResourceResponse
	Metadata PlayerBiddingConfigurationMetadata `json:"metadata"`
}

PlayerBiddingConfigurationResource is the resource that is returned for all Player Bidding Configuration resource requests, with the exception of the Create action, which extends this struct with upload-related data.

type PlayerBiddingConfigurationResourcesResponse

type PlayerBiddingConfigurationResourcesResponse struct {
	V2ResourcesResponse
	PlayerBiddingConfigs []PlayerBiddingConfigurationResource `json:"vpb_configs"`
}

PlayerBiddingConfigurationResourcesResponse is the response structure for Player Bidding Configuration list calls.

type PlayerBiddingWriteRequest

type PlayerBiddingWriteRequest struct {
	Metadata PlayerBiddingConfigurationMetadata `json:"metadata"`
}

PlayerBiddingWriteRequest is the request structure required for Player Bidding Configuration create and update calls.

type QueryParams

type QueryParams struct {
	PageLength int    `url:"page_length"`
	Page       int    `url:"page"`
	Query      string `url:"q"`
	Sort       string `url:"sort"`
}

QueryParams that can be specified on all resource list calls.

type ReuploadRequest

type ReuploadRequest struct {
	Upload Upload `json:"upload"`
}

ReuploadRequest is the request structure required for Media reupload calls.

type UpdateMediaRequest

type UpdateMediaRequest struct {
	Metadata MediaMetadata `json:"metadata"`
}

UpdateMediaRequest is the request structure required for Media update calls.

type Upload

type Upload struct {
	Method       string `json:"method,omitempty"`
	MimeType     string `json:"mime_type,omitempty"`
	SourceURL    string `json:"source_url,omitempty"`
	DownloadURL  string `json:"download_url,omitempty"`
	TrimInPoint  string `json:"trim_in_point,omitempty"`
	TrimOutPoint string `json:"trim_out_point,omitempty"`
}

Upload contains the data used to describe the upload. Available upload method's include "direct" (default), "multipart", "external", and "fetch".

Direct uploads can be used for assets up to 5GB.

MimeType and SourceURL are required only for "external"

MimeType and DownloadURL are required for "fetch", respectively.

TrimInPoint and TrimOutPoint cannot be specified for "external".

type V2Client

type V2Client struct {
	Version string
	// contains filtered or unexported fields
}

V2Client is a light wrapper around the http.defaultClient for interacting with JW Player V2 Platform APIs

func NewV2Client

func NewV2Client(authToken string) *V2Client

NewV2Client creates an authenticated V2 Client.

func (*V2Client) Do

func (c *V2Client) Do(req *http.Request, v interface{}) error

Do executes the request and parses V2 Platform API errors.

func (*V2Client) Request

func (c *V2Client) Request(method, path string, response interface{}, data interface{}, queryParams url.Values) error

Request performs an authenticated HTTP request to the V2 Platform API.

type V2ResourceResponse

type V2ResourceResponse struct {
	ID            string                 `json:"id"`
	Created       string                 `json:"created"`
	LastModified  string                 `json:"last_modified"`
	Type          string                 `json:"type"`
	Relationships map[string]interface{} `json:"relationships"`
}

V2ResourceResponse describes the response structure for resource calls

type V2ResourcesResponse

type V2ResourcesResponse struct {
	Total      int `json:"total"`
	Page       int `json:"page"`
	PageLength int `json:"page_length"`
}

V2ResourcesResponse describes the response structure for list calls

type WebhookMetadata

type WebhookMetadata struct {
	Name        string   `json:"name"`
	Description string   `json:"description,omitempty"`
	Events      []string `json:"events"`
	Sites       []string `json:"site_ids"`
	WebhookURL  string   `json:"webhook_url"`
}

WebhookMetadata describes a Webhook resource

type WebhookResource

type WebhookResource struct {
	V2ResourceResponse
	Metadata WebhookMetadata `json:"metadata"`
}

WebhookResource is the resource that is returned for all Webhook resource requests, with the exception of the Create action, which extends this struct with upload-related data.

type WebhookResourcesResponse

type WebhookResourcesResponse struct {
	V2ResourcesResponse
	Webhooks []WebhookResource `json:"webhooks"`
}

WebhookResourcesResponse is the response structure for Webhook list calls.

type WebhookWriteRequest

type WebhookWriteRequest struct {
	Metadata WebhookMetadata `json:"metadata"`
}

WebhookWriteRequest is the request structure required for Webhook create and update calls.

type WebhooksClient

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

WebhooksClient for interacting with V2 Webhooks API.

func (*WebhooksClient) Create

func (c *WebhooksClient) Create(webhookMetadata *WebhookMetadata) (*CreateWebhookResponse, error)

Create a Webhook resource.

func (*WebhooksClient) Delete

func (c *WebhooksClient) Delete(webhookID string) error

Delete a Webhook resource by ID.

func (*WebhooksClient) Get

func (c *WebhooksClient) Get(webhookID string) (*WebhookResource, error)

Get a single Webhook resource by ID.

func (*WebhooksClient) List

func (c *WebhooksClient) List(queryParams *QueryParams) (*WebhookResourcesResponse, error)

List all Webhook resources.

func (*WebhooksClient) Update

func (c *WebhooksClient) Update(webhookID string, webhookMetadata *WebhookMetadata) (*WebhookResource, error)

Update a Webhook resource by ID.

Jump to

Keyboard shortcuts

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