From 1de2ccbf53ca2df36322f9f2313e25c92ff43f5b Mon Sep 17 00:00:00 2001 From: Jonas Platte Date: Tue, 4 Feb 2025 15:48:53 +0100 Subject: [PATCH] Bump OpenAPI spec and regenerate libs --- go/internal/openapi/api_message.go | 8 +- .../openapi/api_transformation_template.go | 12 +- ...l_template_in.go => model_connector_in.go} | 126 ++-- go/internal/openapi/model_connector_kind.go | 131 ++++ go/internal/openapi/model_environment_in.go | 72 +- go/internal/openapi/model_integration_in.go | 37 + go/internal/openapi/model_integration_out.go | 37 + .../openapi/model_integration_update.go | 37 + .../model_polling_endpoint_message_out.go | 391 ++++++++++ .../openapi/model_polling_endpoint_out.go | 214 ++++++ go/internal/openapi/model_template_out.go | 12 +- go/internal/openapi/model_template_patch.go | 12 +- go/internal/openapi/model_template_update.go | 12 +- .../model_transformation_template_kind.go | 131 ---- lib-openapi.json | 690 +++++++++++------- 15 files changed, 1411 insertions(+), 511 deletions(-) rename go/internal/openapi/{model_template_in.go => model_connector_in.go} (72%) create mode 100644 go/internal/openapi/model_connector_kind.go create mode 100644 go/internal/openapi/model_polling_endpoint_message_out.go create mode 100644 go/internal/openapi/model_polling_endpoint_out.go delete mode 100644 go/internal/openapi/model_transformation_template_kind.go diff --git a/go/internal/openapi/api_message.go b/go/internal/openapi/api_message.go index 37dbcb2a0..4122b592d 100644 --- a/go/internal/openapi/api_message.go +++ b/go/internal/openapi/api_message.go @@ -284,7 +284,7 @@ func (r ApiV1EventsPublicRequest) After(after time.Time) ApiV1EventsPublicReques return r } -func (r ApiV1EventsPublicRequest) Execute() (*MessageEventsOut, *http.Response, error) { +func (r ApiV1EventsPublicRequest) Execute() (*PollingEndpointOut, *http.Response, error) { return r.ApiService.V1EventsPublicExecute(r) } @@ -308,13 +308,13 @@ func (a *MessageAPIService) V1EventsPublic(ctx context.Context, appId string, si } // Execute executes the request -// @return MessageEventsOut -func (a *MessageAPIService) V1EventsPublicExecute(r ApiV1EventsPublicRequest) (*MessageEventsOut, *http.Response, error) { +// @return PollingEndpointOut +func (a *MessageAPIService) V1EventsPublicExecute(r ApiV1EventsPublicRequest) (*PollingEndpointOut, *http.Response, error) { var ( localVarHTTPMethod = http.MethodGet localVarPostBody interface{} formFiles []formFile - localVarReturnValue *MessageEventsOut + localVarReturnValue *PollingEndpointOut ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "MessageAPIService.V1EventsPublic") diff --git a/go/internal/openapi/api_transformation_template.go b/go/internal/openapi/api_transformation_template.go index 07486a0b8..737a4af62 100644 --- a/go/internal/openapi/api_transformation_template.go +++ b/go/internal/openapi/api_transformation_template.go @@ -223,12 +223,12 @@ func (a *TransformationTemplateAPIService) V1EndpointUpdateHubspotOauthConfigExe type ApiV1TransformationTemplateCreateRequest struct { ctx context.Context ApiService *TransformationTemplateAPIService - templateIn *TemplateIn + connectorIn *ConnectorIn idempotencyKey *string } -func (r ApiV1TransformationTemplateCreateRequest) TemplateIn(templateIn TemplateIn) ApiV1TransformationTemplateCreateRequest { - r.templateIn = &templateIn +func (r ApiV1TransformationTemplateCreateRequest) ConnectorIn(connectorIn ConnectorIn) ApiV1TransformationTemplateCreateRequest { + r.connectorIn = &connectorIn return r } @@ -277,8 +277,8 @@ func (a *TransformationTemplateAPIService) V1TransformationTemplateCreateExecute localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} localVarFormParams := url.Values{} - if r.templateIn == nil { - return localVarReturnValue, nil, reportError("templateIn is required and must be specified") + if r.connectorIn == nil { + return localVarReturnValue, nil, reportError("connectorIn is required and must be specified") } // to determine the Content-Type header @@ -302,7 +302,7 @@ func (a *TransformationTemplateAPIService) V1TransformationTemplateCreateExecute parameterAddToHeaderOrQuery(localVarHeaderParams, "idempotency-key", r.idempotencyKey, "simple", "") } // body params - localVarPostBody = r.templateIn + localVarPostBody = r.connectorIn req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err diff --git a/go/internal/openapi/model_template_in.go b/go/internal/openapi/model_connector_in.go similarity index 72% rename from go/internal/openapi/model_template_in.go rename to go/internal/openapi/model_connector_in.go index b969c2404..fb6079d6a 100644 --- a/go/internal/openapi/model_template_in.go +++ b/go/internal/openapi/model_connector_in.go @@ -16,30 +16,30 @@ import ( "fmt" ) -// checks if the TemplateIn type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &TemplateIn{} +// checks if the ConnectorIn type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ConnectorIn{} -// TemplateIn struct for TemplateIn -type TemplateIn struct { +// ConnectorIn struct for ConnectorIn +type ConnectorIn struct { Description *string `json:"description,omitempty"` FeatureFlag *string `json:"featureFlag,omitempty" validate:"regexp=^[a-zA-Z0-9\\\\-_.]+$"` FilterTypes []string `json:"filterTypes,omitempty"` Instructions *string `json:"instructions,omitempty"` InstructionsLink *string `json:"instructionsLink,omitempty"` - Kind *TransformationTemplateKind `json:"kind,omitempty"` + Kind *ConnectorKind `json:"kind,omitempty"` Logo string `json:"logo"` Name string `json:"name"` Transformation string `json:"transformation"` } -type _TemplateIn TemplateIn +type _ConnectorIn ConnectorIn -// NewTemplateIn instantiates a new TemplateIn object +// NewConnectorIn instantiates a new ConnectorIn object // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewTemplateIn(logo string, name string, transformation string) *TemplateIn { - this := TemplateIn{} +func NewConnectorIn(logo string, name string, transformation string) *ConnectorIn { + this := ConnectorIn{} var description string = "" this.Description = &description var instructions string = "" @@ -50,11 +50,11 @@ func NewTemplateIn(logo string, name string, transformation string) *TemplateIn return &this } -// NewTemplateInWithDefaults instantiates a new TemplateIn object +// NewConnectorInWithDefaults instantiates a new ConnectorIn object // This constructor will only assign default values to properties that have it defined, // but it doesn't guarantee that properties required by API are set -func NewTemplateInWithDefaults() *TemplateIn { - this := TemplateIn{} +func NewConnectorInWithDefaults() *ConnectorIn { + this := ConnectorIn{} var description string = "" this.Description = &description var instructions string = "" @@ -63,7 +63,7 @@ func NewTemplateInWithDefaults() *TemplateIn { } // GetDescription returns the Description field value if set, zero value otherwise. -func (o *TemplateIn) GetDescription() string { +func (o *ConnectorIn) GetDescription() string { if o == nil || IsNil(o.Description) { var ret string return ret @@ -73,7 +73,7 @@ func (o *TemplateIn) GetDescription() string { // GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TemplateIn) GetDescriptionOk() (*string, bool) { +func (o *ConnectorIn) GetDescriptionOk() (*string, bool) { if o == nil || IsNil(o.Description) { return nil, false } @@ -81,7 +81,7 @@ func (o *TemplateIn) GetDescriptionOk() (*string, bool) { } // HasDescription returns a boolean if a field has been set. -func (o *TemplateIn) HasDescription() bool { +func (o *ConnectorIn) HasDescription() bool { if o != nil && !IsNil(o.Description) { return true } @@ -90,12 +90,12 @@ func (o *TemplateIn) HasDescription() bool { } // SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *TemplateIn) SetDescription(v string) { +func (o *ConnectorIn) SetDescription(v string) { o.Description = &v } // GetFeatureFlag returns the FeatureFlag field value if set, zero value otherwise. -func (o *TemplateIn) GetFeatureFlag() string { +func (o *ConnectorIn) GetFeatureFlag() string { if o == nil || IsNil(o.FeatureFlag) { var ret string return ret @@ -105,7 +105,7 @@ func (o *TemplateIn) GetFeatureFlag() string { // GetFeatureFlagOk returns a tuple with the FeatureFlag field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TemplateIn) GetFeatureFlagOk() (*string, bool) { +func (o *ConnectorIn) GetFeatureFlagOk() (*string, bool) { if o == nil || IsNil(o.FeatureFlag) { return nil, false } @@ -113,7 +113,7 @@ func (o *TemplateIn) GetFeatureFlagOk() (*string, bool) { } // HasFeatureFlag returns a boolean if a field has been set. -func (o *TemplateIn) HasFeatureFlag() bool { +func (o *ConnectorIn) HasFeatureFlag() bool { if o != nil && !IsNil(o.FeatureFlag) { return true } @@ -122,12 +122,12 @@ func (o *TemplateIn) HasFeatureFlag() bool { } // SetFeatureFlag gets a reference to the given string and assigns it to the FeatureFlag field. -func (o *TemplateIn) SetFeatureFlag(v string) { +func (o *ConnectorIn) SetFeatureFlag(v string) { o.FeatureFlag = &v } // GetFilterTypes returns the FilterTypes field value if set, zero value otherwise. -func (o *TemplateIn) GetFilterTypes() []string { +func (o *ConnectorIn) GetFilterTypes() []string { if o == nil || IsNil(o.FilterTypes) { var ret []string return ret @@ -137,7 +137,7 @@ func (o *TemplateIn) GetFilterTypes() []string { // GetFilterTypesOk returns a tuple with the FilterTypes field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TemplateIn) GetFilterTypesOk() ([]string, bool) { +func (o *ConnectorIn) GetFilterTypesOk() ([]string, bool) { if o == nil || IsNil(o.FilterTypes) { return nil, false } @@ -145,7 +145,7 @@ func (o *TemplateIn) GetFilterTypesOk() ([]string, bool) { } // HasFilterTypes returns a boolean if a field has been set. -func (o *TemplateIn) HasFilterTypes() bool { +func (o *ConnectorIn) HasFilterTypes() bool { if o != nil && !IsNil(o.FilterTypes) { return true } @@ -154,12 +154,12 @@ func (o *TemplateIn) HasFilterTypes() bool { } // SetFilterTypes gets a reference to the given []string and assigns it to the FilterTypes field. -func (o *TemplateIn) SetFilterTypes(v []string) { +func (o *ConnectorIn) SetFilterTypes(v []string) { o.FilterTypes = v } // GetInstructions returns the Instructions field value if set, zero value otherwise. -func (o *TemplateIn) GetInstructions() string { +func (o *ConnectorIn) GetInstructions() string { if o == nil || IsNil(o.Instructions) { var ret string return ret @@ -169,7 +169,7 @@ func (o *TemplateIn) GetInstructions() string { // GetInstructionsOk returns a tuple with the Instructions field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TemplateIn) GetInstructionsOk() (*string, bool) { +func (o *ConnectorIn) GetInstructionsOk() (*string, bool) { if o == nil || IsNil(o.Instructions) { return nil, false } @@ -177,7 +177,7 @@ func (o *TemplateIn) GetInstructionsOk() (*string, bool) { } // HasInstructions returns a boolean if a field has been set. -func (o *TemplateIn) HasInstructions() bool { +func (o *ConnectorIn) HasInstructions() bool { if o != nil && !IsNil(o.Instructions) { return true } @@ -186,12 +186,12 @@ func (o *TemplateIn) HasInstructions() bool { } // SetInstructions gets a reference to the given string and assigns it to the Instructions field. -func (o *TemplateIn) SetInstructions(v string) { +func (o *ConnectorIn) SetInstructions(v string) { o.Instructions = &v } // GetInstructionsLink returns the InstructionsLink field value if set, zero value otherwise. -func (o *TemplateIn) GetInstructionsLink() string { +func (o *ConnectorIn) GetInstructionsLink() string { if o == nil || IsNil(o.InstructionsLink) { var ret string return ret @@ -201,7 +201,7 @@ func (o *TemplateIn) GetInstructionsLink() string { // GetInstructionsLinkOk returns a tuple with the InstructionsLink field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TemplateIn) GetInstructionsLinkOk() (*string, bool) { +func (o *ConnectorIn) GetInstructionsLinkOk() (*string, bool) { if o == nil || IsNil(o.InstructionsLink) { return nil, false } @@ -209,7 +209,7 @@ func (o *TemplateIn) GetInstructionsLinkOk() (*string, bool) { } // HasInstructionsLink returns a boolean if a field has been set. -func (o *TemplateIn) HasInstructionsLink() bool { +func (o *ConnectorIn) HasInstructionsLink() bool { if o != nil && !IsNil(o.InstructionsLink) { return true } @@ -218,14 +218,14 @@ func (o *TemplateIn) HasInstructionsLink() bool { } // SetInstructionsLink gets a reference to the given string and assigns it to the InstructionsLink field. -func (o *TemplateIn) SetInstructionsLink(v string) { +func (o *ConnectorIn) SetInstructionsLink(v string) { o.InstructionsLink = &v } // GetKind returns the Kind field value if set, zero value otherwise. -func (o *TemplateIn) GetKind() TransformationTemplateKind { +func (o *ConnectorIn) GetKind() ConnectorKind { if o == nil || IsNil(o.Kind) { - var ret TransformationTemplateKind + var ret ConnectorKind return ret } return *o.Kind @@ -233,7 +233,7 @@ func (o *TemplateIn) GetKind() TransformationTemplateKind { // GetKindOk returns a tuple with the Kind field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TemplateIn) GetKindOk() (*TransformationTemplateKind, bool) { +func (o *ConnectorIn) GetKindOk() (*ConnectorKind, bool) { if o == nil || IsNil(o.Kind) { return nil, false } @@ -241,7 +241,7 @@ func (o *TemplateIn) GetKindOk() (*TransformationTemplateKind, bool) { } // HasKind returns a boolean if a field has been set. -func (o *TemplateIn) HasKind() bool { +func (o *ConnectorIn) HasKind() bool { if o != nil && !IsNil(o.Kind) { return true } @@ -249,13 +249,13 @@ func (o *TemplateIn) HasKind() bool { return false } -// SetKind gets a reference to the given TransformationTemplateKind and assigns it to the Kind field. -func (o *TemplateIn) SetKind(v TransformationTemplateKind) { +// SetKind gets a reference to the given ConnectorKind and assigns it to the Kind field. +func (o *ConnectorIn) SetKind(v ConnectorKind) { o.Kind = &v } // GetLogo returns the Logo field value -func (o *TemplateIn) GetLogo() string { +func (o *ConnectorIn) GetLogo() string { if o == nil { var ret string return ret @@ -266,7 +266,7 @@ func (o *TemplateIn) GetLogo() string { // GetLogoOk returns a tuple with the Logo field value // and a boolean to check if the value has been set. -func (o *TemplateIn) GetLogoOk() (*string, bool) { +func (o *ConnectorIn) GetLogoOk() (*string, bool) { if o == nil { return nil, false } @@ -274,12 +274,12 @@ func (o *TemplateIn) GetLogoOk() (*string, bool) { } // SetLogo sets field value -func (o *TemplateIn) SetLogo(v string) { +func (o *ConnectorIn) SetLogo(v string) { o.Logo = v } // GetName returns the Name field value -func (o *TemplateIn) GetName() string { +func (o *ConnectorIn) GetName() string { if o == nil { var ret string return ret @@ -290,7 +290,7 @@ func (o *TemplateIn) GetName() string { // GetNameOk returns a tuple with the Name field value // and a boolean to check if the value has been set. -func (o *TemplateIn) GetNameOk() (*string, bool) { +func (o *ConnectorIn) GetNameOk() (*string, bool) { if o == nil { return nil, false } @@ -298,12 +298,12 @@ func (o *TemplateIn) GetNameOk() (*string, bool) { } // SetName sets field value -func (o *TemplateIn) SetName(v string) { +func (o *ConnectorIn) SetName(v string) { o.Name = v } // GetTransformation returns the Transformation field value -func (o *TemplateIn) GetTransformation() string { +func (o *ConnectorIn) GetTransformation() string { if o == nil { var ret string return ret @@ -314,7 +314,7 @@ func (o *TemplateIn) GetTransformation() string { // GetTransformationOk returns a tuple with the Transformation field value // and a boolean to check if the value has been set. -func (o *TemplateIn) GetTransformationOk() (*string, bool) { +func (o *ConnectorIn) GetTransformationOk() (*string, bool) { if o == nil { return nil, false } @@ -322,11 +322,11 @@ func (o *TemplateIn) GetTransformationOk() (*string, bool) { } // SetTransformation sets field value -func (o *TemplateIn) SetTransformation(v string) { +func (o *ConnectorIn) SetTransformation(v string) { o.Transformation = v } -func (o TemplateIn) MarshalJSON() ([]byte, error) { +func (o ConnectorIn) MarshalJSON() ([]byte, error) { toSerialize,err := o.ToMap() if err != nil { return []byte{}, err @@ -334,7 +334,7 @@ func (o TemplateIn) MarshalJSON() ([]byte, error) { return json.Marshal(toSerialize) } -func (o TemplateIn) ToMap() (map[string]interface{}, error) { +func (o ConnectorIn) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} if !IsNil(o.Description) { toSerialize["description"] = o.Description @@ -360,7 +360,7 @@ func (o TemplateIn) ToMap() (map[string]interface{}, error) { return toSerialize, nil } -func (o *TemplateIn) UnmarshalJSON(data []byte) (err error) { +func (o *ConnectorIn) UnmarshalJSON(data []byte) (err error) { // This validates that all required properties are included in the JSON object // by unmarshalling the object into a generic map with string keys and checking // that every required field exists as a key in the generic map. @@ -384,53 +384,53 @@ func (o *TemplateIn) UnmarshalJSON(data []byte) (err error) { } } - varTemplateIn := _TemplateIn{} + varConnectorIn := _ConnectorIn{} decoder := json.NewDecoder(bytes.NewReader(data)) decoder.DisallowUnknownFields() - err = decoder.Decode(&varTemplateIn) + err = decoder.Decode(&varConnectorIn) if err != nil { return err } - *o = TemplateIn(varTemplateIn) + *o = ConnectorIn(varConnectorIn) return err } -type NullableTemplateIn struct { - value *TemplateIn +type NullableConnectorIn struct { + value *ConnectorIn isSet bool } -func (v NullableTemplateIn) Get() *TemplateIn { +func (v NullableConnectorIn) Get() *ConnectorIn { return v.value } -func (v *NullableTemplateIn) Set(val *TemplateIn) { +func (v *NullableConnectorIn) Set(val *ConnectorIn) { v.value = val v.isSet = true } -func (v NullableTemplateIn) IsSet() bool { +func (v NullableConnectorIn) IsSet() bool { return v.isSet } -func (v *NullableTemplateIn) Unset() { +func (v *NullableConnectorIn) Unset() { v.value = nil v.isSet = false } -func NewNullableTemplateIn(val *TemplateIn) *NullableTemplateIn { - return &NullableTemplateIn{value: val, isSet: true} +func NewNullableConnectorIn(val *ConnectorIn) *NullableConnectorIn { + return &NullableConnectorIn{value: val, isSet: true} } -func (v NullableTemplateIn) MarshalJSON() ([]byte, error) { +func (v NullableConnectorIn) MarshalJSON() ([]byte, error) { return json.Marshal(v.value) } -func (v *NullableTemplateIn) UnmarshalJSON(src []byte) error { +func (v *NullableConnectorIn) UnmarshalJSON(src []byte) error { v.isSet = true return json.Unmarshal(src, &v.value) } diff --git a/go/internal/openapi/model_connector_kind.go b/go/internal/openapi/model_connector_kind.go new file mode 100644 index 000000000..1c581c127 --- /dev/null +++ b/go/internal/openapi/model_connector_kind.go @@ -0,0 +1,131 @@ +/* +Svix API + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package openapi + +import ( + "encoding/json" + "fmt" +) + +// ConnectorKind the model 'ConnectorKind' +type ConnectorKind string + +// List of ConnectorKind +const ( + CONNECTORKIND_CUSTOM ConnectorKind = "Custom" + CONNECTORKIND_CUSTOMER_IO ConnectorKind = "CustomerIO" + CONNECTORKIND_DISCORD ConnectorKind = "Discord" + CONNECTORKIND_HUBSPOT ConnectorKind = "Hubspot" + CONNECTORKIND_INNGEST ConnectorKind = "Inngest" + CONNECTORKIND_SALESFORCE ConnectorKind = "Salesforce" + CONNECTORKIND_SEGMENT ConnectorKind = "Segment" + CONNECTORKIND_SLACK ConnectorKind = "Slack" + CONNECTORKIND_TEAMS ConnectorKind = "Teams" + CONNECTORKIND_TRIGGER_DEV ConnectorKind = "TriggerDev" + CONNECTORKIND_WINDMILL ConnectorKind = "Windmill" + CONNECTORKIND_ZAPIER ConnectorKind = "Zapier" +) + +// All allowed values of ConnectorKind enum +var AllowedConnectorKindEnumValues = []ConnectorKind{ + "Custom", + "CustomerIO", + "Discord", + "Hubspot", + "Inngest", + "Salesforce", + "Segment", + "Slack", + "Teams", + "TriggerDev", + "Windmill", + "Zapier", +} + +func (v *ConnectorKind) UnmarshalJSON(src []byte) error { + var value string + err := json.Unmarshal(src, &value) + if err != nil { + return err + } + enumTypeValue := ConnectorKind(value) + for _, existing := range AllowedConnectorKindEnumValues { + if existing == enumTypeValue { + *v = enumTypeValue + return nil + } + } + + return fmt.Errorf("%+v is not a valid ConnectorKind", value) +} + +// NewConnectorKindFromValue returns a pointer to a valid ConnectorKind +// for the value passed as argument, or an error if the value passed is not allowed by the enum +func NewConnectorKindFromValue(v string) (*ConnectorKind, error) { + ev := ConnectorKind(v) + if ev.IsValid() { + return &ev, nil + } else { + return nil, fmt.Errorf("invalid value '%v' for ConnectorKind: valid values are %v", v, AllowedConnectorKindEnumValues) + } +} + +// IsValid return true if the value is valid for the enum, false otherwise +func (v ConnectorKind) IsValid() bool { + for _, existing := range AllowedConnectorKindEnumValues { + if existing == v { + return true + } + } + return false +} + +// Ptr returns reference to ConnectorKind value +func (v ConnectorKind) Ptr() *ConnectorKind { + return &v +} + +type NullableConnectorKind struct { + value *ConnectorKind + isSet bool +} + +func (v NullableConnectorKind) Get() *ConnectorKind { + return v.value +} + +func (v *NullableConnectorKind) Set(val *ConnectorKind) { + v.value = val + v.isSet = true +} + +func (v NullableConnectorKind) IsSet() bool { + return v.isSet +} + +func (v *NullableConnectorKind) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableConnectorKind(val *ConnectorKind) *NullableConnectorKind { + return &NullableConnectorKind{value: val, isSet: true} +} + +func (v NullableConnectorKind) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableConnectorKind) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + diff --git a/go/internal/openapi/model_environment_in.go b/go/internal/openapi/model_environment_in.go index 459ae9944..2ec9e4d7c 100644 --- a/go/internal/openapi/model_environment_in.go +++ b/go/internal/openapi/model_environment_in.go @@ -19,9 +19,9 @@ var _ MappedNullable = &EnvironmentIn{} // EnvironmentIn struct for EnvironmentIn type EnvironmentIn struct { + Connectors []ConnectorIn `json:"connectors,omitempty"` EventTypes []EventTypeIn `json:"eventTypes,omitempty"` Settings map[string]interface{} `json:"settings,omitempty"` - TransformationTemplates []TemplateIn `json:"transformationTemplates,omitempty"` } // NewEnvironmentIn instantiates a new EnvironmentIn object @@ -41,6 +41,38 @@ func NewEnvironmentInWithDefaults() *EnvironmentIn { return &this } +// GetConnectors returns the Connectors field value if set, zero value otherwise. +func (o *EnvironmentIn) GetConnectors() []ConnectorIn { + if o == nil || IsNil(o.Connectors) { + var ret []ConnectorIn + return ret + } + return o.Connectors +} + +// GetConnectorsOk returns a tuple with the Connectors field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *EnvironmentIn) GetConnectorsOk() ([]ConnectorIn, bool) { + if o == nil || IsNil(o.Connectors) { + return nil, false + } + return o.Connectors, true +} + +// HasConnectors returns a boolean if a field has been set. +func (o *EnvironmentIn) HasConnectors() bool { + if o != nil && !IsNil(o.Connectors) { + return true + } + + return false +} + +// SetConnectors gets a reference to the given []ConnectorIn and assigns it to the Connectors field. +func (o *EnvironmentIn) SetConnectors(v []ConnectorIn) { + o.Connectors = v +} + // GetEventTypes returns the EventTypes field value if set, zero value otherwise. func (o *EnvironmentIn) GetEventTypes() []EventTypeIn { if o == nil || IsNil(o.EventTypes) { @@ -105,38 +137,6 @@ func (o *EnvironmentIn) SetSettings(v map[string]interface{}) { o.Settings = v } -// GetTransformationTemplates returns the TransformationTemplates field value if set, zero value otherwise. -func (o *EnvironmentIn) GetTransformationTemplates() []TemplateIn { - if o == nil || IsNil(o.TransformationTemplates) { - var ret []TemplateIn - return ret - } - return o.TransformationTemplates -} - -// GetTransformationTemplatesOk returns a tuple with the TransformationTemplates field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *EnvironmentIn) GetTransformationTemplatesOk() ([]TemplateIn, bool) { - if o == nil || IsNil(o.TransformationTemplates) { - return nil, false - } - return o.TransformationTemplates, true -} - -// HasTransformationTemplates returns a boolean if a field has been set. -func (o *EnvironmentIn) HasTransformationTemplates() bool { - if o != nil && !IsNil(o.TransformationTemplates) { - return true - } - - return false -} - -// SetTransformationTemplates gets a reference to the given []TemplateIn and assigns it to the TransformationTemplates field. -func (o *EnvironmentIn) SetTransformationTemplates(v []TemplateIn) { - o.TransformationTemplates = v -} - func (o EnvironmentIn) MarshalJSON() ([]byte, error) { toSerialize,err := o.ToMap() if err != nil { @@ -147,15 +147,15 @@ func (o EnvironmentIn) MarshalJSON() ([]byte, error) { func (o EnvironmentIn) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} + if !IsNil(o.Connectors) { + toSerialize["connectors"] = o.Connectors + } if !IsNil(o.EventTypes) { toSerialize["eventTypes"] = o.EventTypes } if !IsNil(o.Settings) { toSerialize["settings"] = o.Settings } - if !IsNil(o.TransformationTemplates) { - toSerialize["transformationTemplates"] = o.TransformationTemplates - } return toSerialize, nil } diff --git a/go/internal/openapi/model_integration_in.go b/go/internal/openapi/model_integration_in.go index 82105efb0..57366f904 100644 --- a/go/internal/openapi/model_integration_in.go +++ b/go/internal/openapi/model_integration_in.go @@ -21,6 +21,8 @@ var _ MappedNullable = &IntegrationIn{} // IntegrationIn struct for IntegrationIn type IntegrationIn struct { + // The set of feature flags the integration will have access to. + FeatureFlags []string `json:"featureFlags,omitempty"` Name string `json:"name"` } @@ -44,6 +46,38 @@ func NewIntegrationInWithDefaults() *IntegrationIn { return &this } +// GetFeatureFlags returns the FeatureFlags field value if set, zero value otherwise. +func (o *IntegrationIn) GetFeatureFlags() []string { + if o == nil || IsNil(o.FeatureFlags) { + var ret []string + return ret + } + return o.FeatureFlags +} + +// GetFeatureFlagsOk returns a tuple with the FeatureFlags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *IntegrationIn) GetFeatureFlagsOk() ([]string, bool) { + if o == nil || IsNil(o.FeatureFlags) { + return nil, false + } + return o.FeatureFlags, true +} + +// HasFeatureFlags returns a boolean if a field has been set. +func (o *IntegrationIn) HasFeatureFlags() bool { + if o != nil && !IsNil(o.FeatureFlags) { + return true + } + + return false +} + +// SetFeatureFlags gets a reference to the given []string and assigns it to the FeatureFlags field. +func (o *IntegrationIn) SetFeatureFlags(v []string) { + o.FeatureFlags = v +} + // GetName returns the Name field value func (o *IntegrationIn) GetName() string { if o == nil { @@ -78,6 +112,9 @@ func (o IntegrationIn) MarshalJSON() ([]byte, error) { func (o IntegrationIn) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} + if !IsNil(o.FeatureFlags) { + toSerialize["featureFlags"] = o.FeatureFlags + } toSerialize["name"] = o.Name return toSerialize, nil } diff --git a/go/internal/openapi/model_integration_out.go b/go/internal/openapi/model_integration_out.go index 3228e2200..65dadfa25 100644 --- a/go/internal/openapi/model_integration_out.go +++ b/go/internal/openapi/model_integration_out.go @@ -23,6 +23,8 @@ var _ MappedNullable = &IntegrationOut{} // IntegrationOut struct for IntegrationOut type IntegrationOut struct { CreatedAt time.Time `json:"createdAt"` + // The set of feature flags the integration has access to. + FeatureFlags []string `json:"featureFlags,omitempty"` // The integ's ID Id string `json:"id"` Name string `json:"name"` @@ -76,6 +78,38 @@ func (o *IntegrationOut) SetCreatedAt(v time.Time) { o.CreatedAt = v } +// GetFeatureFlags returns the FeatureFlags field value if set, zero value otherwise. +func (o *IntegrationOut) GetFeatureFlags() []string { + if o == nil || IsNil(o.FeatureFlags) { + var ret []string + return ret + } + return o.FeatureFlags +} + +// GetFeatureFlagsOk returns a tuple with the FeatureFlags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *IntegrationOut) GetFeatureFlagsOk() ([]string, bool) { + if o == nil || IsNil(o.FeatureFlags) { + return nil, false + } + return o.FeatureFlags, true +} + +// HasFeatureFlags returns a boolean if a field has been set. +func (o *IntegrationOut) HasFeatureFlags() bool { + if o != nil && !IsNil(o.FeatureFlags) { + return true + } + + return false +} + +// SetFeatureFlags gets a reference to the given []string and assigns it to the FeatureFlags field. +func (o *IntegrationOut) SetFeatureFlags(v []string) { + o.FeatureFlags = v +} + // GetId returns the Id field value func (o *IntegrationOut) GetId() string { if o == nil { @@ -159,6 +193,9 @@ func (o IntegrationOut) MarshalJSON() ([]byte, error) { func (o IntegrationOut) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} toSerialize["createdAt"] = o.CreatedAt + if !IsNil(o.FeatureFlags) { + toSerialize["featureFlags"] = o.FeatureFlags + } toSerialize["id"] = o.Id toSerialize["name"] = o.Name toSerialize["updatedAt"] = o.UpdatedAt diff --git a/go/internal/openapi/model_integration_update.go b/go/internal/openapi/model_integration_update.go index 6b49dabea..aad18e028 100644 --- a/go/internal/openapi/model_integration_update.go +++ b/go/internal/openapi/model_integration_update.go @@ -21,6 +21,8 @@ var _ MappedNullable = &IntegrationUpdate{} // IntegrationUpdate struct for IntegrationUpdate type IntegrationUpdate struct { + // The set of feature flags the integration will have access to. + FeatureFlags []string `json:"featureFlags,omitempty"` Name string `json:"name"` } @@ -44,6 +46,38 @@ func NewIntegrationUpdateWithDefaults() *IntegrationUpdate { return &this } +// GetFeatureFlags returns the FeatureFlags field value if set, zero value otherwise. +func (o *IntegrationUpdate) GetFeatureFlags() []string { + if o == nil || IsNil(o.FeatureFlags) { + var ret []string + return ret + } + return o.FeatureFlags +} + +// GetFeatureFlagsOk returns a tuple with the FeatureFlags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *IntegrationUpdate) GetFeatureFlagsOk() ([]string, bool) { + if o == nil || IsNil(o.FeatureFlags) { + return nil, false + } + return o.FeatureFlags, true +} + +// HasFeatureFlags returns a boolean if a field has been set. +func (o *IntegrationUpdate) HasFeatureFlags() bool { + if o != nil && !IsNil(o.FeatureFlags) { + return true + } + + return false +} + +// SetFeatureFlags gets a reference to the given []string and assigns it to the FeatureFlags field. +func (o *IntegrationUpdate) SetFeatureFlags(v []string) { + o.FeatureFlags = v +} + // GetName returns the Name field value func (o *IntegrationUpdate) GetName() string { if o == nil { @@ -78,6 +112,9 @@ func (o IntegrationUpdate) MarshalJSON() ([]byte, error) { func (o IntegrationUpdate) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} + if !IsNil(o.FeatureFlags) { + toSerialize["featureFlags"] = o.FeatureFlags + } toSerialize["name"] = o.Name return toSerialize, nil } diff --git a/go/internal/openapi/model_polling_endpoint_message_out.go b/go/internal/openapi/model_polling_endpoint_message_out.go new file mode 100644 index 000000000..432461732 --- /dev/null +++ b/go/internal/openapi/model_polling_endpoint_message_out.go @@ -0,0 +1,391 @@ +/* +Svix API + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package openapi + +import ( + "encoding/json" + "time" + "bytes" + "fmt" +) + +// checks if the PollingEndpointMessageOut type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &PollingEndpointMessageOut{} + +// PollingEndpointMessageOut The MessageOut equivalent of polling endpoint +type PollingEndpointMessageOut struct { + // List of free-form identifiers that endpoints can filter by + Channels []string `json:"channels,omitempty"` + // Optional unique identifier for the message + EventId *string `json:"eventId,omitempty" validate:"regexp=^[a-zA-Z0-9\\\\-_.]+$"` + // The event type's name + EventType string `json:"eventType" validate:"regexp=^[a-zA-Z0-9\\\\-_.]+$"` + Headers *map[string]string `json:"headers,omitempty"` + // The msg's ID + Id string `json:"id"` + Payload map[string]interface{} `json:"payload"` + Tags []string `json:"tags,omitempty"` + Timestamp time.Time `json:"timestamp"` +} + +type _PollingEndpointMessageOut PollingEndpointMessageOut + +// NewPollingEndpointMessageOut instantiates a new PollingEndpointMessageOut object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPollingEndpointMessageOut(eventType string, id string, payload map[string]interface{}, timestamp time.Time) *PollingEndpointMessageOut { + this := PollingEndpointMessageOut{} + this.EventType = eventType + this.Id = id + this.Payload = payload + this.Timestamp = timestamp + return &this +} + +// NewPollingEndpointMessageOutWithDefaults instantiates a new PollingEndpointMessageOut object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPollingEndpointMessageOutWithDefaults() *PollingEndpointMessageOut { + this := PollingEndpointMessageOut{} + return &this +} + +// GetChannels returns the Channels field value if set, zero value otherwise. +func (o *PollingEndpointMessageOut) GetChannels() []string { + if o == nil || IsNil(o.Channels) { + var ret []string + return ret + } + return o.Channels +} + +// GetChannelsOk returns a tuple with the Channels field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PollingEndpointMessageOut) GetChannelsOk() ([]string, bool) { + if o == nil || IsNil(o.Channels) { + return nil, false + } + return o.Channels, true +} + +// HasChannels returns a boolean if a field has been set. +func (o *PollingEndpointMessageOut) HasChannels() bool { + if o != nil && !IsNil(o.Channels) { + return true + } + + return false +} + +// SetChannels gets a reference to the given []string and assigns it to the Channels field. +func (o *PollingEndpointMessageOut) SetChannels(v []string) { + o.Channels = v +} + +// GetEventId returns the EventId field value if set, zero value otherwise. +func (o *PollingEndpointMessageOut) GetEventId() string { + if o == nil || IsNil(o.EventId) { + var ret string + return ret + } + return *o.EventId +} + +// GetEventIdOk returns a tuple with the EventId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PollingEndpointMessageOut) GetEventIdOk() (*string, bool) { + if o == nil || IsNil(o.EventId) { + return nil, false + } + return o.EventId, true +} + +// HasEventId returns a boolean if a field has been set. +func (o *PollingEndpointMessageOut) HasEventId() bool { + if o != nil && !IsNil(o.EventId) { + return true + } + + return false +} + +// SetEventId gets a reference to the given string and assigns it to the EventId field. +func (o *PollingEndpointMessageOut) SetEventId(v string) { + o.EventId = &v +} + +// GetEventType returns the EventType field value +func (o *PollingEndpointMessageOut) GetEventType() string { + if o == nil { + var ret string + return ret + } + + return o.EventType +} + +// GetEventTypeOk returns a tuple with the EventType field value +// and a boolean to check if the value has been set. +func (o *PollingEndpointMessageOut) GetEventTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.EventType, true +} + +// SetEventType sets field value +func (o *PollingEndpointMessageOut) SetEventType(v string) { + o.EventType = v +} + +// GetHeaders returns the Headers field value if set, zero value otherwise. +func (o *PollingEndpointMessageOut) GetHeaders() map[string]string { + if o == nil || IsNil(o.Headers) { + var ret map[string]string + return ret + } + return *o.Headers +} + +// GetHeadersOk returns a tuple with the Headers field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PollingEndpointMessageOut) GetHeadersOk() (*map[string]string, bool) { + if o == nil || IsNil(o.Headers) { + return nil, false + } + return o.Headers, true +} + +// HasHeaders returns a boolean if a field has been set. +func (o *PollingEndpointMessageOut) HasHeaders() bool { + if o != nil && !IsNil(o.Headers) { + return true + } + + return false +} + +// SetHeaders gets a reference to the given map[string]string and assigns it to the Headers field. +func (o *PollingEndpointMessageOut) SetHeaders(v map[string]string) { + o.Headers = &v +} + +// GetId returns the Id field value +func (o *PollingEndpointMessageOut) GetId() string { + if o == nil { + var ret string + return ret + } + + return o.Id +} + +// GetIdOk returns a tuple with the Id field value +// and a boolean to check if the value has been set. +func (o *PollingEndpointMessageOut) GetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Id, true +} + +// SetId sets field value +func (o *PollingEndpointMessageOut) SetId(v string) { + o.Id = v +} + +// GetPayload returns the Payload field value +func (o *PollingEndpointMessageOut) GetPayload() map[string]interface{} { + if o == nil { + var ret map[string]interface{} + return ret + } + + return o.Payload +} + +// GetPayloadOk returns a tuple with the Payload field value +// and a boolean to check if the value has been set. +func (o *PollingEndpointMessageOut) GetPayloadOk() (map[string]interface{}, bool) { + if o == nil { + return map[string]interface{}{}, false + } + return o.Payload, true +} + +// SetPayload sets field value +func (o *PollingEndpointMessageOut) SetPayload(v map[string]interface{}) { + o.Payload = v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *PollingEndpointMessageOut) GetTags() []string { + if o == nil || IsNil(o.Tags) { + var ret []string + return ret + } + return o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PollingEndpointMessageOut) GetTagsOk() ([]string, bool) { + if o == nil || IsNil(o.Tags) { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *PollingEndpointMessageOut) HasTags() bool { + if o != nil && !IsNil(o.Tags) { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *PollingEndpointMessageOut) SetTags(v []string) { + o.Tags = v +} + +// GetTimestamp returns the Timestamp field value +func (o *PollingEndpointMessageOut) GetTimestamp() time.Time { + if o == nil { + var ret time.Time + return ret + } + + return o.Timestamp +} + +// GetTimestampOk returns a tuple with the Timestamp field value +// and a boolean to check if the value has been set. +func (o *PollingEndpointMessageOut) GetTimestampOk() (*time.Time, bool) { + if o == nil { + return nil, false + } + return &o.Timestamp, true +} + +// SetTimestamp sets field value +func (o *PollingEndpointMessageOut) SetTimestamp(v time.Time) { + o.Timestamp = v +} + +func (o PollingEndpointMessageOut) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o PollingEndpointMessageOut) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Channels) { + toSerialize["channels"] = o.Channels + } + if !IsNil(o.EventId) { + toSerialize["eventId"] = o.EventId + } + toSerialize["eventType"] = o.EventType + if !IsNil(o.Headers) { + toSerialize["headers"] = o.Headers + } + toSerialize["id"] = o.Id + toSerialize["payload"] = o.Payload + if !IsNil(o.Tags) { + toSerialize["tags"] = o.Tags + } + toSerialize["timestamp"] = o.Timestamp + return toSerialize, nil +} + +func (o *PollingEndpointMessageOut) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "eventType", + "id", + "payload", + "timestamp", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varPollingEndpointMessageOut := _PollingEndpointMessageOut{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varPollingEndpointMessageOut) + + if err != nil { + return err + } + + *o = PollingEndpointMessageOut(varPollingEndpointMessageOut) + + return err +} + +type NullablePollingEndpointMessageOut struct { + value *PollingEndpointMessageOut + isSet bool +} + +func (v NullablePollingEndpointMessageOut) Get() *PollingEndpointMessageOut { + return v.value +} + +func (v *NullablePollingEndpointMessageOut) Set(val *PollingEndpointMessageOut) { + v.value = val + v.isSet = true +} + +func (v NullablePollingEndpointMessageOut) IsSet() bool { + return v.isSet +} + +func (v *NullablePollingEndpointMessageOut) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePollingEndpointMessageOut(val *PollingEndpointMessageOut) *NullablePollingEndpointMessageOut { + return &NullablePollingEndpointMessageOut{value: val, isSet: true} +} + +func (v NullablePollingEndpointMessageOut) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePollingEndpointMessageOut) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/go/internal/openapi/model_polling_endpoint_out.go b/go/internal/openapi/model_polling_endpoint_out.go new file mode 100644 index 000000000..d5a4fdbe1 --- /dev/null +++ b/go/internal/openapi/model_polling_endpoint_out.go @@ -0,0 +1,214 @@ +/* +Svix API + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package openapi + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the PollingEndpointOut type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &PollingEndpointOut{} + +// PollingEndpointOut struct for PollingEndpointOut +type PollingEndpointOut struct { + Data []PollingEndpointMessageOut `json:"data"` + Done bool `json:"done"` + Iterator string `json:"iterator"` +} + +type _PollingEndpointOut PollingEndpointOut + +// NewPollingEndpointOut instantiates a new PollingEndpointOut object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPollingEndpointOut(data []PollingEndpointMessageOut, done bool, iterator string) *PollingEndpointOut { + this := PollingEndpointOut{} + this.Data = data + this.Done = done + this.Iterator = iterator + return &this +} + +// NewPollingEndpointOutWithDefaults instantiates a new PollingEndpointOut object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPollingEndpointOutWithDefaults() *PollingEndpointOut { + this := PollingEndpointOut{} + return &this +} + +// GetData returns the Data field value +func (o *PollingEndpointOut) GetData() []PollingEndpointMessageOut { + if o == nil { + var ret []PollingEndpointMessageOut + return ret + } + + return o.Data +} + +// GetDataOk returns a tuple with the Data field value +// and a boolean to check if the value has been set. +func (o *PollingEndpointOut) GetDataOk() ([]PollingEndpointMessageOut, bool) { + if o == nil { + return nil, false + } + return o.Data, true +} + +// SetData sets field value +func (o *PollingEndpointOut) SetData(v []PollingEndpointMessageOut) { + o.Data = v +} + +// GetDone returns the Done field value +func (o *PollingEndpointOut) GetDone() bool { + if o == nil { + var ret bool + return ret + } + + return o.Done +} + +// GetDoneOk returns a tuple with the Done field value +// and a boolean to check if the value has been set. +func (o *PollingEndpointOut) GetDoneOk() (*bool, bool) { + if o == nil { + return nil, false + } + return &o.Done, true +} + +// SetDone sets field value +func (o *PollingEndpointOut) SetDone(v bool) { + o.Done = v +} + +// GetIterator returns the Iterator field value +func (o *PollingEndpointOut) GetIterator() string { + if o == nil { + var ret string + return ret + } + + return o.Iterator +} + +// GetIteratorOk returns a tuple with the Iterator field value +// and a boolean to check if the value has been set. +func (o *PollingEndpointOut) GetIteratorOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Iterator, true +} + +// SetIterator sets field value +func (o *PollingEndpointOut) SetIterator(v string) { + o.Iterator = v +} + +func (o PollingEndpointOut) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o PollingEndpointOut) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["data"] = o.Data + toSerialize["done"] = o.Done + toSerialize["iterator"] = o.Iterator + return toSerialize, nil +} + +func (o *PollingEndpointOut) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "data", + "done", + "iterator", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varPollingEndpointOut := _PollingEndpointOut{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varPollingEndpointOut) + + if err != nil { + return err + } + + *o = PollingEndpointOut(varPollingEndpointOut) + + return err +} + +type NullablePollingEndpointOut struct { + value *PollingEndpointOut + isSet bool +} + +func (v NullablePollingEndpointOut) Get() *PollingEndpointOut { + return v.value +} + +func (v *NullablePollingEndpointOut) Set(val *PollingEndpointOut) { + v.value = val + v.isSet = true +} + +func (v NullablePollingEndpointOut) IsSet() bool { + return v.isSet +} + +func (v *NullablePollingEndpointOut) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePollingEndpointOut(val *PollingEndpointOut) *NullablePollingEndpointOut { + return &NullablePollingEndpointOut{value: val, isSet: true} +} + +func (v NullablePollingEndpointOut) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePollingEndpointOut) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/go/internal/openapi/model_template_out.go b/go/internal/openapi/model_template_out.go index d2231da1c..1254f2cd9 100644 --- a/go/internal/openapi/model_template_out.go +++ b/go/internal/openapi/model_template_out.go @@ -29,7 +29,7 @@ type TemplateOut struct { Id string `json:"id"` Instructions string `json:"instructions"` InstructionsLink *string `json:"instructionsLink,omitempty"` - Kind TransformationTemplateKind `json:"kind"` + Kind ConnectorKind `json:"kind"` Logo string `json:"logo"` Name string `json:"name"` OrgId string `json:"orgId"` @@ -43,7 +43,7 @@ type _TemplateOut TemplateOut // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewTemplateOut(createdAt time.Time, description string, id string, instructions string, kind TransformationTemplateKind, logo string, name string, orgId string, transformation string, updatedAt time.Time) *TemplateOut { +func NewTemplateOut(createdAt time.Time, description string, id string, instructions string, kind ConnectorKind, logo string, name string, orgId string, transformation string, updatedAt time.Time) *TemplateOut { this := TemplateOut{} this.CreatedAt = createdAt this.Description = description @@ -259,9 +259,9 @@ func (o *TemplateOut) SetInstructionsLink(v string) { } // GetKind returns the Kind field value -func (o *TemplateOut) GetKind() TransformationTemplateKind { +func (o *TemplateOut) GetKind() ConnectorKind { if o == nil { - var ret TransformationTemplateKind + var ret ConnectorKind return ret } @@ -270,7 +270,7 @@ func (o *TemplateOut) GetKind() TransformationTemplateKind { // GetKindOk returns a tuple with the Kind field value // and a boolean to check if the value has been set. -func (o *TemplateOut) GetKindOk() (*TransformationTemplateKind, bool) { +func (o *TemplateOut) GetKindOk() (*ConnectorKind, bool) { if o == nil { return nil, false } @@ -278,7 +278,7 @@ func (o *TemplateOut) GetKindOk() (*TransformationTemplateKind, bool) { } // SetKind sets field value -func (o *TemplateOut) SetKind(v TransformationTemplateKind) { +func (o *TemplateOut) SetKind(v ConnectorKind) { o.Kind = v } diff --git a/go/internal/openapi/model_template_patch.go b/go/internal/openapi/model_template_patch.go index 8352735cb..0e4baa768 100644 --- a/go/internal/openapi/model_template_patch.go +++ b/go/internal/openapi/model_template_patch.go @@ -24,7 +24,7 @@ type TemplatePatch struct { FilterTypes []string `json:"filterTypes,omitempty"` Instructions *string `json:"instructions,omitempty"` InstructionsLink NullableString `json:"instructionsLink,omitempty"` - Kind *TransformationTemplateKind `json:"kind,omitempty"` + Kind *ConnectorKind `json:"kind,omitempty"` Logo *string `json:"logo,omitempty"` Name *string `json:"name,omitempty"` Transformation *string `json:"transformation,omitempty"` @@ -229,9 +229,9 @@ func (o *TemplatePatch) UnsetInstructionsLink() { } // GetKind returns the Kind field value if set, zero value otherwise. -func (o *TemplatePatch) GetKind() TransformationTemplateKind { +func (o *TemplatePatch) GetKind() ConnectorKind { if o == nil || IsNil(o.Kind) { - var ret TransformationTemplateKind + var ret ConnectorKind return ret } return *o.Kind @@ -239,7 +239,7 @@ func (o *TemplatePatch) GetKind() TransformationTemplateKind { // GetKindOk returns a tuple with the Kind field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TemplatePatch) GetKindOk() (*TransformationTemplateKind, bool) { +func (o *TemplatePatch) GetKindOk() (*ConnectorKind, bool) { if o == nil || IsNil(o.Kind) { return nil, false } @@ -255,8 +255,8 @@ func (o *TemplatePatch) HasKind() bool { return false } -// SetKind gets a reference to the given TransformationTemplateKind and assigns it to the Kind field. -func (o *TemplatePatch) SetKind(v TransformationTemplateKind) { +// SetKind gets a reference to the given ConnectorKind and assigns it to the Kind field. +func (o *TemplatePatch) SetKind(v ConnectorKind) { o.Kind = &v } diff --git a/go/internal/openapi/model_template_update.go b/go/internal/openapi/model_template_update.go index 9001fd1f1..75600a746 100644 --- a/go/internal/openapi/model_template_update.go +++ b/go/internal/openapi/model_template_update.go @@ -26,7 +26,7 @@ type TemplateUpdate struct { FilterTypes []string `json:"filterTypes,omitempty"` Instructions *string `json:"instructions,omitempty"` InstructionsLink *string `json:"instructionsLink,omitempty"` - Kind *TransformationTemplateKind `json:"kind,omitempty"` + Kind *ConnectorKind `json:"kind,omitempty"` Logo string `json:"logo"` Name *string `json:"name,omitempty"` Transformation string `json:"transformation"` @@ -226,9 +226,9 @@ func (o *TemplateUpdate) SetInstructionsLink(v string) { } // GetKind returns the Kind field value if set, zero value otherwise. -func (o *TemplateUpdate) GetKind() TransformationTemplateKind { +func (o *TemplateUpdate) GetKind() ConnectorKind { if o == nil || IsNil(o.Kind) { - var ret TransformationTemplateKind + var ret ConnectorKind return ret } return *o.Kind @@ -236,7 +236,7 @@ func (o *TemplateUpdate) GetKind() TransformationTemplateKind { // GetKindOk returns a tuple with the Kind field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TemplateUpdate) GetKindOk() (*TransformationTemplateKind, bool) { +func (o *TemplateUpdate) GetKindOk() (*ConnectorKind, bool) { if o == nil || IsNil(o.Kind) { return nil, false } @@ -252,8 +252,8 @@ func (o *TemplateUpdate) HasKind() bool { return false } -// SetKind gets a reference to the given TransformationTemplateKind and assigns it to the Kind field. -func (o *TemplateUpdate) SetKind(v TransformationTemplateKind) { +// SetKind gets a reference to the given ConnectorKind and assigns it to the Kind field. +func (o *TemplateUpdate) SetKind(v ConnectorKind) { o.Kind = &v } diff --git a/go/internal/openapi/model_transformation_template_kind.go b/go/internal/openapi/model_transformation_template_kind.go deleted file mode 100644 index 514d555cf..000000000 --- a/go/internal/openapi/model_transformation_template_kind.go +++ /dev/null @@ -1,131 +0,0 @@ -/* -Svix API - -No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - -API version: 1.1.1 -*/ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package openapi - -import ( - "encoding/json" - "fmt" -) - -// TransformationTemplateKind the model 'TransformationTemplateKind' -type TransformationTemplateKind string - -// List of TransformationTemplateKind -const ( - TRANSFORMATIONTEMPLATEKIND_CUSTOM TransformationTemplateKind = "Custom" - TRANSFORMATIONTEMPLATEKIND_CUSTOMER_IO TransformationTemplateKind = "CustomerIO" - TRANSFORMATIONTEMPLATEKIND_DISCORD TransformationTemplateKind = "Discord" - TRANSFORMATIONTEMPLATEKIND_HUBSPOT TransformationTemplateKind = "Hubspot" - TRANSFORMATIONTEMPLATEKIND_INNGEST TransformationTemplateKind = "Inngest" - TRANSFORMATIONTEMPLATEKIND_SALESFORCE TransformationTemplateKind = "Salesforce" - TRANSFORMATIONTEMPLATEKIND_SEGMENT TransformationTemplateKind = "Segment" - TRANSFORMATIONTEMPLATEKIND_SLACK TransformationTemplateKind = "Slack" - TRANSFORMATIONTEMPLATEKIND_TEAMS TransformationTemplateKind = "Teams" - TRANSFORMATIONTEMPLATEKIND_TRIGGER_DEV TransformationTemplateKind = "TriggerDev" - TRANSFORMATIONTEMPLATEKIND_WINDMILL TransformationTemplateKind = "Windmill" - TRANSFORMATIONTEMPLATEKIND_ZAPIER TransformationTemplateKind = "Zapier" -) - -// All allowed values of TransformationTemplateKind enum -var AllowedTransformationTemplateKindEnumValues = []TransformationTemplateKind{ - "Custom", - "CustomerIO", - "Discord", - "Hubspot", - "Inngest", - "Salesforce", - "Segment", - "Slack", - "Teams", - "TriggerDev", - "Windmill", - "Zapier", -} - -func (v *TransformationTemplateKind) UnmarshalJSON(src []byte) error { - var value string - err := json.Unmarshal(src, &value) - if err != nil { - return err - } - enumTypeValue := TransformationTemplateKind(value) - for _, existing := range AllowedTransformationTemplateKindEnumValues { - if existing == enumTypeValue { - *v = enumTypeValue - return nil - } - } - - return fmt.Errorf("%+v is not a valid TransformationTemplateKind", value) -} - -// NewTransformationTemplateKindFromValue returns a pointer to a valid TransformationTemplateKind -// for the value passed as argument, or an error if the value passed is not allowed by the enum -func NewTransformationTemplateKindFromValue(v string) (*TransformationTemplateKind, error) { - ev := TransformationTemplateKind(v) - if ev.IsValid() { - return &ev, nil - } else { - return nil, fmt.Errorf("invalid value '%v' for TransformationTemplateKind: valid values are %v", v, AllowedTransformationTemplateKindEnumValues) - } -} - -// IsValid return true if the value is valid for the enum, false otherwise -func (v TransformationTemplateKind) IsValid() bool { - for _, existing := range AllowedTransformationTemplateKindEnumValues { - if existing == v { - return true - } - } - return false -} - -// Ptr returns reference to TransformationTemplateKind value -func (v TransformationTemplateKind) Ptr() *TransformationTemplateKind { - return &v -} - -type NullableTransformationTemplateKind struct { - value *TransformationTemplateKind - isSet bool -} - -func (v NullableTransformationTemplateKind) Get() *TransformationTemplateKind { - return v.value -} - -func (v *NullableTransformationTemplateKind) Set(val *TransformationTemplateKind) { - v.value = val - v.isSet = true -} - -func (v NullableTransformationTemplateKind) IsSet() bool { - return v.isSet -} - -func (v *NullableTransformationTemplateKind) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableTransformationTemplateKind(val *TransformationTemplateKind) *NullableTransformationTemplateKind { - return &NullableTransformationTemplateKind{value: val, isSet: true} -} - -func (v NullableTransformationTemplateKind) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableTransformationTemplateKind) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} - diff --git a/lib-openapi.json b/lib-openapi.json index 1daa450e3..37c3b28f8 100644 --- a/lib-openapi.json +++ b/lib-openapi.json @@ -539,6 +539,7 @@ "BackgroundTaskOut": { "properties": { "data": { + "additionalProperties": true, "type": "object" }, "id": { @@ -694,6 +695,87 @@ ], "type": "object" }, + "ConnectorIn": { + "properties": { + "description": { + "default": "", + "type": "string" + }, + "featureFlag": { + "example": "cool-new-feature", + "maxLength": 256, + "nullable": true, + "pattern": "^[a-zA-Z0-9\\-_.]+$", + "type": "string" + }, + "filterTypes": { + "example": [ + "user.signup", + "user.deleted" + ], + "items": { + "description": "The event type's name", + "example": "user.signup", + "maxLength": 256, + "pattern": "^[a-zA-Z0-9\\-_.]+$", + "type": "string" + }, + "minItems": 1, + "nullable": true, + "type": "array", + "uniqueItems": true + }, + "instructions": { + "default": "", + "type": "string" + }, + "instructionsLink": { + "default": null, + "format": "uri", + "nullable": true, + "type": "string" + }, + "kind": { + "$ref": "#/components/schemas/ConnectorKind", + "default": "Custom" + }, + "logo": { + "format": "uri", + "type": "string" + }, + "name": { + "type": "string" + }, + "transformation": { + "maxLength": 51200, + "minLength": 10, + "type": "string" + } + }, + "required": [ + "logo", + "name", + "transformation" + ], + "type": "object" + }, + "ConnectorKind": { + "enum": [ + "Custom", + "CustomerIO", + "Discord", + "Hubspot", + "Inngest", + "Salesforce", + "Segment", + "Slack", + "Teams", + "TriggerDev", + "Windmill", + "Zapier" + ], + "type": "string" + }, "CountOut": { "properties": { "approximated": { @@ -1414,6 +1496,7 @@ "type": "string" }, "payload": { + "additionalProperties": true, "example": { "email": "test@example.com", "type": "user.created", @@ -1849,6 +1932,7 @@ "type": "string" }, "payload": { + "additionalProperties": true, "type": "object" } }, @@ -2032,6 +2116,13 @@ }, "EnvironmentIn": { "properties": { + "connectors": { + "items": { + "$ref": "#/components/schemas/ConnectorIn" + }, + "nullable": true, + "type": "array" + }, "eventTypes": { "items": { "$ref": "#/components/schemas/EventTypeIn" @@ -2040,15 +2131,9 @@ "type": "array" }, "settings": { + "additionalProperties": true, "nullable": true, "type": "object" - }, - "transformationTemplates": { - "items": { - "$ref": "#/components/schemas/TemplateIn" - }, - "nullable": true, - "type": "array" } }, "type": "object" @@ -2066,6 +2151,7 @@ "type": "array" }, "settings": { + "additionalProperties": true, "nullable": true, "type": "object" }, @@ -2261,6 +2347,7 @@ "EventTypeExampleOut": { "properties": { "example": { + "additionalProperties": true, "example": { "data": { "email": "test@example.com", @@ -2307,6 +2394,7 @@ "type": "string" }, "schemas": { + "additionalProperties": true, "example": { "description": "An invoice was paid by a user", "properties": { @@ -2351,6 +2439,7 @@ "type": "boolean" }, "spec": { + "additionalProperties": true, "description": "A pre-parsed JSON spec.", "example": { "info": { @@ -2400,49 +2489,7 @@ }, "specRaw": { "description": "A string, parsed by the server as YAML or JSON.", - "example": { - "info": { - "title": "Webhook Example", - "version": "1.0.0" - }, - "openapi": "3.1.0", - "webhooks": { - "pet.new": { - "post": { - "requestBody": { - "content": { - "application/json": { - "schema": { - "properties": { - "id": { - "format": "int64", - "type": "integer" - }, - "name": { - "type": "string" - }, - "tag": { - "type": "string" - } - }, - "required": [ - "id", - "name" - ] - } - } - }, - "description": "Information about a new pet in the system" - }, - "responses": { - "200": { - "description": "Return a 200 status to indicate that the data was received successfully" - } - } - } - } - } - }, + "example": "\n# Both YAML and JSON are supported\nopenapi: 3.1.0\ninfo:\n title: Webhook Example\n version: 1.0.0\n# Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\nwebhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n\ncomponents:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n", "nullable": true, "type": "string" } @@ -2523,6 +2570,7 @@ "type": "string" }, "schemas": { + "additionalProperties": true, "description": "The schema for the event type for a specific version as a JSON schema.", "example": { "1": { @@ -2596,6 +2644,7 @@ "type": "string" }, "schemas": { + "additionalProperties": true, "description": "The schema for the event type for a specific version as a JSON schema.", "example": { "1": { @@ -2662,6 +2711,7 @@ "type": "string" }, "schemas": { + "additionalProperties": true, "example": { "description": "An invoice was paid by a user", "properties": { @@ -2690,6 +2740,7 @@ "EventTypeSchemaIn": { "properties": { "schema": { + "additionalProperties": true, "example": { "description": "An invoice was paid by a user", "properties": { @@ -2748,6 +2799,7 @@ "type": "string" }, "schemas": { + "additionalProperties": true, "description": "The schema for the event type for a specific version as a JSON schema.", "example": { "1": { @@ -2949,6 +3001,20 @@ }, "IntegrationIn": { "properties": { + "featureFlags": { + "description": "The set of feature flags the integration will have access to.", + "example": [], + "items": { + "example": "cool-new-feature", + "maxLength": 256, + "pattern": "^[a-zA-Z0-9\\-_.]+$", + "type": "string" + }, + "maxItems": 25, + "minItems": 1, + "type": "array", + "uniqueItems": true + }, "name": { "example": "Example Integration", "type": "string" @@ -2977,6 +3043,21 @@ "format": "date-time", "type": "string" }, + "featureFlags": { + "default": [], + "description": "The set of feature flags the integration has access to.", + "example": [], + "items": { + "example": "cool-new-feature", + "maxLength": 256, + "pattern": "^[a-zA-Z0-9\\-_.]+$", + "type": "string" + }, + "maxItems": 25, + "minItems": 1, + "type": "array", + "uniqueItems": true + }, "id": { "description": "The integ's ID", "example": "integ_1srOrx2ZWZBpBUvZwXKQmoEYga2", @@ -3001,6 +3082,20 @@ }, "IntegrationUpdate": { "properties": { + "featureFlags": { + "description": "The set of feature flags the integration will have access to.", + "example": [], + "items": { + "example": "cool-new-feature", + "maxLength": 256, + "pattern": "^[a-zA-Z0-9\\-_.]+$", + "type": "string" + }, + "maxItems": 25, + "minItems": 1, + "type": "array", + "uniqueItems": true + }, "name": { "example": "Example Integration", "type": "string" @@ -3957,6 +4052,7 @@ "type": "string" }, "payload": { + "additionalProperties": true, "example": { "email": "test@example.com", "type": "user.created", @@ -4181,6 +4277,7 @@ "type": "string" }, "payload": { + "additionalProperties": true, "description": "JSON payload to send as the request body of the webhook.\n\nWe also support sending non-JSON payloads. Please contact us for more information.", "example": { "email": "test@example.com", @@ -4226,6 +4323,7 @@ "uniqueItems": true }, "transformationsParams": { + "additionalProperties": true, "description": "Extra parameters to pass to Transformations (for future use)", "nullable": true, "type": "object" @@ -4279,6 +4377,7 @@ "type": "string" }, "payload": { + "additionalProperties": true, "example": { "email": "test@example.com", "type": "user.created", @@ -4724,6 +4823,110 @@ ], "type": "string" }, + "PollingEndpointMessageOut": { + "description": "The MessageOut equivalent of polling endpoint", + "properties": { + "channels": { + "description": "List of free-form identifiers that endpoints can filter by", + "example": [ + "project_123", + "group_2" + ], + "items": { + "example": "project_1337", + "maxLength": 128, + "pattern": "^[a-zA-Z0-9\\-_.:]+$", + "type": "string" + }, + "maxItems": 10, + "minItems": 1, + "nullable": true, + "type": "array", + "uniqueItems": true + }, + "eventId": { + "description": "Optional unique identifier for the message", + "example": "unique-msg-identifier", + "maxLength": 256, + "minLength": 1, + "nullable": true, + "pattern": "^[a-zA-Z0-9\\-_.]+$", + "type": "string" + }, + "eventType": { + "description": "The event type's name", + "example": "user.signup", + "maxLength": 256, + "pattern": "^[a-zA-Z0-9\\-_.]+$", + "type": "string" + }, + "headers": { + "additionalProperties": { + "type": "string" + }, + "nullable": true, + "type": "object" + }, + "id": { + "description": "The msg's ID", + "example": "msg_1srOrx2ZWZBpBUvZwXKQmoEYga2", + "type": "string" + }, + "payload": { + "additionalProperties": true, + "example": { + "email": "test@example.com", + "type": "user.created", + "username": "test_user" + }, + "type": "object" + }, + "tags": { + "items": { + "example": "project_1337", + "maxLength": 128, + "pattern": "^[a-zA-Z0-9\\-_.]+$", + "type": "string" + }, + "nullable": true, + "type": "array", + "uniqueItems": true + }, + "timestamp": { + "format": "date-time", + "type": "string" + } + }, + "required": [ + "eventType", + "id", + "payload", + "timestamp" + ], + "type": "object" + }, + "PollingEndpointOut": { + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/PollingEndpointMessageOut" + }, + "type": "array" + }, + "done": { + "type": "boolean" + }, + "iterator": { + "type": "string" + } + }, + "required": [ + "data", + "done", + "iterator" + ], + "type": "object" + }, "RecoverIn": { "properties": { "since": { @@ -6270,70 +6473,6 @@ "pattern": "^(?!strm_)[a-zA-Z0-9_-]+$", "type": "string" }, - "TemplateIn": { - "properties": { - "description": { - "default": "", - "type": "string" - }, - "featureFlag": { - "example": "cool-new-feature", - "maxLength": 256, - "nullable": true, - "pattern": "^[a-zA-Z0-9\\-_.]+$", - "type": "string" - }, - "filterTypes": { - "example": [ - "user.signup", - "user.deleted" - ], - "items": { - "description": "The event type's name", - "example": "user.signup", - "maxLength": 256, - "pattern": "^[a-zA-Z0-9\\-_.]+$", - "type": "string" - }, - "minItems": 1, - "nullable": true, - "type": "array", - "uniqueItems": true - }, - "instructions": { - "default": "", - "type": "string" - }, - "instructionsLink": { - "default": null, - "format": "uri", - "nullable": true, - "type": "string" - }, - "kind": { - "$ref": "#/components/schemas/TransformationTemplateKind", - "default": "Custom" - }, - "logo": { - "format": "uri", - "type": "string" - }, - "name": { - "type": "string" - }, - "transformation": { - "maxLength": 51200, - "minLength": 10, - "type": "string" - } - }, - "required": [ - "logo", - "name", - "transformation" - ], - "type": "object" - }, "TemplateOut": { "properties": { "createdAt": { @@ -6379,7 +6518,7 @@ "type": "string" }, "kind": { - "$ref": "#/components/schemas/TransformationTemplateKind" + "$ref": "#/components/schemas/ConnectorKind" }, "logo": { "format": "uri", @@ -6451,7 +6590,7 @@ "type": "string" }, "kind": { - "$ref": "#/components/schemas/TransformationTemplateKind" + "$ref": "#/components/schemas/ConnectorKind" }, "logo": { "format": "uri", @@ -6508,7 +6647,7 @@ "type": "string" }, "kind": { - "$ref": "#/components/schemas/TransformationTemplateKind", + "$ref": "#/components/schemas/ConnectorKind", "default": "Custom" }, "logo": { @@ -6565,6 +6704,7 @@ "type": "string" }, "payload": { + "additionalProperties": true, "type": "object" } }, @@ -6597,23 +6737,6 @@ ], "type": "object" }, - "TransformationTemplateKind": { - "enum": [ - "Custom", - "CustomerIO", - "Discord", - "Hubspot", - "Inngest", - "Salesforce", - "Segment", - "Slack", - "Teams", - "TriggerDev", - "Windmill", - "Zapier" - ], - "type": "string" - }, "ValidationError": { "description": "Validation errors have their own schema to provide context for invalid requests eg. mismatched types and out of bounds values. There may be any number of these per 422 UNPROCESSABLE ENTITY error.", "properties": { @@ -7209,7 +7332,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/app/stats/usage' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}": { @@ -8549,7 +8673,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/attempt/endpoint/{endpoint_id}/count' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/attempt/msg/{msg_id}": { @@ -11112,7 +11237,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/endpoint/{endpoint_id}/msg/test-attempt' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"eventId\": \"unique-msg-identifier\",\n \"eventType\": \"user.signup\",\n \"payload\": {\"email\":\"test@example.com\",\"type\":\"user.created\",\"username\":\"test_user\"},\n \"channels\": [\"project_123\", \"group_2\"],\n \"application\": null,\n \"tags\": [\"my_tag\", \"other\"],\n \"transformationsParams\": null,\n \"payloadRetentionPeriod\": 90,\n \"payloadRetentionHours\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/endpoint/{endpoint_id}/mtls": { @@ -11296,7 +11422,8 @@ "lang": "Shell", "source": "curl -X 'DELETE' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/endpoint/{endpoint_id}/mtls' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "put": { "description": "Create / update endpoint mTLS configuration.", @@ -11488,7 +11615,8 @@ "lang": "Shell", "source": "curl -X 'PUT' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/endpoint/{endpoint_id}/mtls' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"serverCaCert\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/endpoint/{endpoint_id}/oauth": { @@ -11672,7 +11800,8 @@ "lang": "Shell", "source": "curl -X 'DELETE' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/endpoint/{endpoint_id}/oauth' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "get": { "description": "Get endpoint OAuth configuration.", @@ -11861,7 +11990,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/endpoint/{endpoint_id}/oauth' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "put": { "description": "Create / update endpoint OAuth configuration.", @@ -12053,7 +12183,8 @@ "lang": "Shell", "source": "curl -X 'PUT' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/endpoint/{endpoint_id}/oauth' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"jwtParams\": null,\n \"clientSecret\": null,\n \"scopes\": null,\n \"extraParams\": null,\n \"refreshToken\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/endpoint/{endpoint_id}/recover": { @@ -13869,7 +14000,8 @@ "lang": "Shell", "source": "curl -X 'PUT' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/endpoint/{endpoint_id}/transformation-template/oauth/hubspot' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/endpoint/{endpoint_id}/transformation/simulate": { @@ -14079,7 +14211,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/endpoint/{endpoint_id}/transformation/simulate' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"eventType\": \"user.signup\",\n \"channels\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/events": { @@ -14326,7 +14459,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/events' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/events/subscription/{subscription_id}": { @@ -14588,7 +14722,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/events/subscription/{subscription_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/events/subscription/{subscription_id}/create-token": { @@ -14733,7 +14868,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/events/subscription/{subscription_id}/create-token' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/inbound/msg/{inbound_token}": { @@ -14951,7 +15087,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/inbound/msg/{inbound_token}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/inbound/rotate-url": { @@ -15136,7 +15273,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/inbound/rotate-url' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/integration": { @@ -15484,62 +15622,62 @@ { "label": "JavaScript", "lang": "JavaScript", - "source": "const integrationOut = await svix.integration.create(\"app_id\", {\n name: \"Example Integration\"\n});" + "source": "const integrationOut = await svix.integration.create(\"app_id\", {\n name: \"Example Integration\",\n featureFlags: []\n});" }, { "label": "TypeScript", "lang": "JavaScript", - "source": "const integrationOut = await svix.integration.create(\"app_id\", {\n name: \"Example Integration\"\n});" + "source": "const integrationOut = await svix.integration.create(\"app_id\", {\n name: \"Example Integration\",\n featureFlags: []\n});" }, { "label": "Python", "lang": "Python", - "source": "integration_out = svix.integration.create(\"app_id\", IntegrationIn(\n name=\"Example Integration\"\n), options=...)" + "source": "integration_out = svix.integration.create(\"app_id\", IntegrationIn(\n name=\"Example Integration\",\n feature_flags=[]\n), options=...)" }, { "label": "Python (Async)", "lang": "Python", - "source": "integration_out = await svix.integration.create(\"app_id\", IntegrationIn(\n name=\"Example Integration\"\n), options=...)" + "source": "integration_out = await svix.integration.create(\"app_id\", IntegrationIn(\n name=\"Example Integration\",\n feature_flags=[]\n), options=...)" }, { "label": "Go", "lang": "Go", - "source": "integrationOut, err := svixClient.Integration.Create(ctx, \"app_id\", &IntegrationIn{\n Name: \"Example Integration\",\n})" + "source": "integrationOut, err := svixClient.Integration.Create(ctx, \"app_id\", &IntegrationIn{\n Name: \"Example Integration\",\n FeatureFlags: []interface{}{},\n})" }, { "label": "Kotlin", "lang": "Kotlin", - "source": "val integrationOut = svix.integration.create(\"app_id\", IntegrationIn()\n .name(\"Example Integration\")\n)" + "source": "val integrationOut = svix.integration.create(\"app_id\", IntegrationIn()\n .name(\"Example Integration\")\n .featureFlags(arrayOf())\n)" }, { "label": "Java", "lang": "Java", - "source": "IntegrationOut integrationOut = svix.getIntegration().create(\"app_id\", new IntegrationIn()\n .name(\"Example Integration\")\n);" + "source": "IntegrationOut integrationOut = svix.getIntegration().create(\"app_id\", new IntegrationIn()\n .name(\"Example Integration\")\n .featureFlags(new Object[]{})\n);" }, { "label": "Ruby", "lang": "Ruby", - "source": "integration_out = svix.integration.create(\"app_id\", Svix::IntegrationIn.new({\n \"name\": \"Example Integration\"\n}))" + "source": "integration_out = svix.integration.create(\"app_id\", Svix::IntegrationIn.new({\n \"name\": \"Example Integration\",\n \"feature_flags\": []\n}))" }, { "label": "Rust", "lang": "Rust", - "source": "let integration_out = svix.integration().create(\"app_id\", IntegrationIn {\n name: \"Example Integration\".to_string(),\n}, None).await?;" + "source": "let integration_out = svix.integration().create(\"app_id\", IntegrationIn {\n name: \"Example Integration\".to_string(),\n feature_flags: Some(vec![]),\n}, None).await?;" }, { "label": "C#", "lang": "C#", - "source": "var integrationOut = await svix.Integration.CreateAsync(\"app_id\", new IntegrationIn{\n name: \"Example Integration\"\n});" + "source": "var integrationOut = await svix.Integration.CreateAsync(\"app_id\", new IntegrationIn{\n name: \"Example Integration\",\n featureFlags: new Object[] {}\n});" }, { "label": "CLI", "lang": "Shell", - "source": "svix integration create \"app_id\" '{\n \"name\": \"Example Integration\"\n}'" + "source": "svix integration create \"app_id\" '{\n \"name\": \"Example Integration\",\n \"featureFlags\": []\n}'" }, { "label": "cURL", "lang": "Shell", - "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/integration' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"name\": \"Example Integration\"\n }'" + "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/integration' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"name\": \"Example Integration\",\n \"featureFlags\": []\n }'" } ] } @@ -16047,62 +16185,62 @@ { "label": "JavaScript", "lang": "JavaScript", - "source": "const integrationOut = await svix.integration.update(\"app_id\", \"integ_id\", {\n name: \"Example Integration\"\n});" + "source": "const integrationOut = await svix.integration.update(\"app_id\", \"integ_id\", {\n name: \"Example Integration\",\n featureFlags: []\n});" }, { "label": "TypeScript", "lang": "JavaScript", - "source": "const integrationOut = await svix.integration.update(\"app_id\", \"integ_id\", {\n name: \"Example Integration\"\n});" + "source": "const integrationOut = await svix.integration.update(\"app_id\", \"integ_id\", {\n name: \"Example Integration\",\n featureFlags: []\n});" }, { "label": "Python", "lang": "Python", - "source": "integration_out = svix.integration.update(\"app_id\", \"integ_id\", IntegrationUpdate(\n name=\"Example Integration\"\n))" + "source": "integration_out = svix.integration.update(\"app_id\", \"integ_id\", IntegrationUpdate(\n name=\"Example Integration\",\n feature_flags=[]\n))" }, { "label": "Python (Async)", "lang": "Python", - "source": "integration_out = await svix.integration.update(\"app_id\", \"integ_id\", IntegrationUpdate(\n name=\"Example Integration\"\n))" + "source": "integration_out = await svix.integration.update(\"app_id\", \"integ_id\", IntegrationUpdate(\n name=\"Example Integration\",\n feature_flags=[]\n))" }, { "label": "Go", "lang": "Go", - "source": "integrationOut, err := svixClient.Integration.Update(ctx, \"app_id\", \"integ_id\", &IntegrationUpdate{\n Name: \"Example Integration\",\n})" + "source": "integrationOut, err := svixClient.Integration.Update(ctx, \"app_id\", \"integ_id\", &IntegrationUpdate{\n Name: \"Example Integration\",\n FeatureFlags: []interface{}{},\n})" }, { "label": "Kotlin", "lang": "Kotlin", - "source": "val integrationOut = svix.integration.update(\"app_id\", \"integ_id\", IntegrationUpdate()\n .name(\"Example Integration\")\n)" + "source": "val integrationOut = svix.integration.update(\"app_id\", \"integ_id\", IntegrationUpdate()\n .name(\"Example Integration\")\n .featureFlags(arrayOf())\n)" }, { "label": "Java", "lang": "Java", - "source": "IntegrationOut integrationOut = svix.getIntegration().update(\"app_id\", \"integ_id\", new IntegrationUpdate()\n .name(\"Example Integration\")\n);" + "source": "IntegrationOut integrationOut = svix.getIntegration().update(\"app_id\", \"integ_id\", new IntegrationUpdate()\n .name(\"Example Integration\")\n .featureFlags(new Object[]{})\n);" }, { "label": "Ruby", "lang": "Ruby", - "source": "integration_out = svix.integration.update(\"app_id\", \"integ_id\", Svix::IntegrationUpdate.new({\n \"name\": \"Example Integration\"\n}))" + "source": "integration_out = svix.integration.update(\"app_id\", \"integ_id\", Svix::IntegrationUpdate.new({\n \"name\": \"Example Integration\",\n \"feature_flags\": []\n}))" }, { "label": "Rust", "lang": "Rust", - "source": "let integration_out = svix.integration().update(\"app_id\", \"integ_id\", IntegrationUpdate {\n name: \"Example Integration\".to_string(),\n}).await?;" + "source": "let integration_out = svix.integration().update(\"app_id\", \"integ_id\", IntegrationUpdate {\n name: \"Example Integration\".to_string(),\n feature_flags: Some(vec![]),\n}).await?;" }, { "label": "C#", "lang": "C#", - "source": "var integrationOut = await svix.Integration.UpdateAsync(\"app_id\", \"integ_id\", new IntegrationUpdate{\n name: \"Example Integration\"\n});" + "source": "var integrationOut = await svix.Integration.UpdateAsync(\"app_id\", \"integ_id\", new IntegrationUpdate{\n name: \"Example Integration\",\n featureFlags: new Object[] {}\n});" }, { "label": "CLI", "lang": "Shell", - "source": "svix integration update \"app_id\" \"integ_id\" '{\n \"name\": \"Example Integration\"\n}'" + "source": "svix integration update \"app_id\" \"integ_id\" '{\n \"name\": \"Example Integration\",\n \"featureFlags\": []\n}'" }, { "label": "cURL", "lang": "Shell", - "source": "curl -X 'PUT' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/integration/{integ_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"name\": \"Example Integration\"\n }'" + "source": "curl -X 'PUT' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/integration/{integ_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"name\": \"Example Integration\",\n \"featureFlags\": []\n }'" } ] } @@ -17791,7 +17929,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/msg/{msg_id}/attempt/{attempt_id}/headers' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/msg/{msg_id}/content": { @@ -18590,7 +18729,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/msg/{msg_id}/raw' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/poller/{sink_id}": { @@ -18696,7 +18836,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/MessageEventsOut" + "$ref": "#/components/schemas/PollingEndpointOut" } } }, @@ -18788,7 +18928,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/poller/{sink_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/sink": { @@ -19000,7 +19141,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/sink' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "post": { "description": "Create a new sink for the application.", @@ -19193,7 +19335,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/sink' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"description\": \"An example endpoint name\",\n \"rateLimit\": null,\n \"uid\": \"unique-ep-identifier\",\n \"secret\": \"whsec_C2FVsBQIhrscChlQIMV+b5sSYspob7oD\",\n \"disabled\": false,\n \"filterTypes\": [\"user.signup\", \"user.deleted\"],\n \"channels\": [\"project_123\", \"group_2\"]\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/sink/{sink_id}": { @@ -19384,7 +19527,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/sink/{sink_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/app/{app_id}/stats": { @@ -19584,7 +19728,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/app/{app_id}/stats' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/auth/app-portal-access/{app_id}": { @@ -19974,7 +20119,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/auth/app/{app_id}/create-message-token' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"expiry\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/auth/app/{app_id}/expire-all": { @@ -20353,7 +20499,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/auth/app/{app_id}/poller/{endpoint_id}/token' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/auth/app/{app_id}/poller/{endpoint_id}/token/rotate": { @@ -20563,7 +20710,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/auth/app/{app_id}/poller/{endpoint_id}/token/rotate' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"expiry\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/auth/dashboard-access/{app_id}": { @@ -21092,7 +21240,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/auth/one-time-token' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/auth/stream-portal-access/{stream_id}": { @@ -21281,7 +21430,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/auth/stream-portal-access/{stream_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"featureFlags\": [],\n \"expiry\": null,\n \"readOnly\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/background-task": { @@ -21955,62 +22105,62 @@ { "label": "JavaScript", "lang": "JavaScript", - "source": "await svix.environment.import({\n eventTypes: null,\n settings: null,\n transformationTemplates: null\n});" + "source": "await svix.environment.import({\n eventTypes: null,\n settings: null,\n connectors: null\n});" }, { "label": "TypeScript", "lang": "JavaScript", - "source": "await svix.environment.import({\n eventTypes: null,\n settings: null,\n transformationTemplates: null\n});" + "source": "await svix.environment.import({\n eventTypes: null,\n settings: null,\n connectors: null\n});" }, { "label": "Python", "lang": "Python", - "source": "svix.environment.import(EnvironmentIn(\n event_types=None,\n settings=None,\n transformation_templates=None\n), options=...)" + "source": "svix.environment.import(EnvironmentIn(\n event_types=None,\n settings=None,\n connectors=None\n), options=...)" }, { "label": "Python (Async)", "lang": "Python", - "source": "await svix.environment.import(EnvironmentIn(\n event_types=None,\n settings=None,\n transformation_templates=None\n), options=...)" + "source": "await svix.environment.import(EnvironmentIn(\n event_types=None,\n settings=None,\n connectors=None\n), options=...)" }, { "label": "Go", "lang": "Go", - "source": "err := svixClient.Environment.Import(ctx, &EnvironmentIn{\n EventTypes: nil,\n Settings: nil,\n TransformationTemplates: nil,\n})" + "source": "err := svixClient.Environment.Import(ctx, &EnvironmentIn{\n EventTypes: nil,\n Settings: nil,\n Connectors: nil,\n})" }, { "label": "Kotlin", "lang": "Kotlin", - "source": "svix.environment.import(EnvironmentIn()\n .eventTypes(null)\n .settings(null)\n .transformationTemplates(null)\n)" + "source": "svix.environment.import(EnvironmentIn()\n .eventTypes(null)\n .settings(null)\n .connectors(null)\n)" }, { "label": "Java", "lang": "Java", - "source": "svix.getEnvironment().import(new EnvironmentIn()\n .eventTypes(null)\n .settings(null)\n .transformationTemplates(null)\n);" + "source": "svix.getEnvironment().import(new EnvironmentIn()\n .eventTypes(null)\n .settings(null)\n .connectors(null)\n);" }, { "label": "Ruby", "lang": "Ruby", - "source": "svix.environment.import(Svix::EnvironmentIn.new({\n \"event_types\": nil,\n \"settings\": nil,\n \"transformation_templates\": nil\n}))" + "source": "svix.environment.import(Svix::EnvironmentIn.new({\n \"event_types\": nil,\n \"settings\": nil,\n \"connectors\": nil\n}))" }, { "label": "Rust", "lang": "Rust", - "source": "svix.environment().import(EnvironmentIn {\n event_types: None,\n settings: None,\n transformation_templates: None,\n}, None).await?;" + "source": "svix.environment().import(EnvironmentIn {\n event_types: None,\n settings: None,\n connectors: None,\n}, None).await?;" }, { "label": "C#", "lang": "C#", - "source": "await svix.Environment.ImportAsync(new EnvironmentIn{\n eventTypes: null,\n settings: null,\n transformationTemplates: null\n});" + "source": "await svix.Environment.ImportAsync(new EnvironmentIn{\n eventTypes: null,\n settings: null,\n connectors: null\n});" }, { "label": "CLI", "lang": "Shell", - "source": "svix environment import '{\n \"eventTypes\": null,\n \"settings\": null,\n \"transformationTemplates\": null\n}'" + "source": "svix environment import '{\n \"eventTypes\": null,\n \"settings\": null,\n \"connectors\": null\n}'" }, { "label": "cURL", "lang": "Shell", - "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/environment/import' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"eventTypes\": null,\n \"settings\": null,\n \"transformationTemplates\": null\n }'" + "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/environment/import' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"eventTypes\": null,\n \"settings\": null,\n \"connectors\": null\n }'" } ] } @@ -22171,7 +22321,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/environment/settings' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/event-type": { @@ -22740,7 +22891,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/event-type/export/openapi' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/event-type/import/openapi": { @@ -22864,62 +23016,62 @@ { "label": "JavaScript", "lang": "JavaScript", - "source": "const eventTypeImportOpenApiOut = await svix.eventType.importOpenapi({\n spec: {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n specRaw: {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}}\n});" + "source": "const eventTypeImportOpenApiOut = await svix.eventType.importOpenapi({\n spec: {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n specRaw: \"\n# Both YAML and JSON are supported\nopenapi: 3.1.0\ninfo:\n title: Webhook Example\n version: 1.0.0\n# Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\nwebhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n\ncomponents:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n\"\n});" }, { "label": "TypeScript", "lang": "JavaScript", - "source": "const eventTypeImportOpenApiOut = await svix.eventType.importOpenapi({\n spec: {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n specRaw: {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}}\n});" + "source": "const eventTypeImportOpenApiOut = await svix.eventType.importOpenapi({\n spec: {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n specRaw: \"\n# Both YAML and JSON are supported\nopenapi: 3.1.0\ninfo:\n title: Webhook Example\n version: 1.0.0\n# Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\nwebhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n\ncomponents:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n\"\n});" }, { "label": "Python", "lang": "Python", - "source": "event_type_import_open_api_out = svix.event_type.import_openapi(EventTypeImportOpenApiIn(\n spec={\"info\": {\"title\": \"Webhook Example\", \"version\": \"1.0.0\"}, \"openapi\": \"3.1.0\", \"webhooks\": {\"pet.new\": {\"post\": {\"requestBody\": {\"content\": {\"application/json\": {\"schema\": {\"properties\": {\"id\": {\"format\": \"int64\", \"type\": \"integer\"}, \"name\": {\"type\": \"string\"}, \"tag\": {\"type\": \"string\"}}, \"required\": [\"id\", \"name\"]}}}, \"description\": \"Information about a new pet in the system\"}, \"responses\": {\"200\": {\"description\": \"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n spec_raw={\"info\": {\"title\": \"Webhook Example\", \"version\": \"1.0.0\"}, \"openapi\": \"3.1.0\", \"webhooks\": {\"pet.new\": {\"post\": {\"requestBody\": {\"content\": {\"application/json\": {\"schema\": {\"properties\": {\"id\": {\"format\": \"int64\", \"type\": \"integer\"}, \"name\": {\"type\": \"string\"}, \"tag\": {\"type\": \"string\"}}, \"required\": [\"id\", \"name\"]}}}, \"description\": \"Information about a new pet in the system\"}, \"responses\": {\"200\": {\"description\": \"Return a 200 status to indicate that the data was received successfully\"}}}}}}\n), options=...)" + "source": "event_type_import_open_api_out = svix.event_type.import_openapi(EventTypeImportOpenApiIn(\n spec={\"info\": {\"title\": \"Webhook Example\", \"version\": \"1.0.0\"}, \"openapi\": \"3.1.0\", \"webhooks\": {\"pet.new\": {\"post\": {\"requestBody\": {\"content\": {\"application/json\": {\"schema\": {\"properties\": {\"id\": {\"format\": \"int64\", \"type\": \"integer\"}, \"name\": {\"type\": \"string\"}, \"tag\": {\"type\": \"string\"}}, \"required\": [\"id\", \"name\"]}}}, \"description\": \"Information about a new pet in the system\"}, \"responses\": {\"200\": {\"description\": \"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n spec_raw=\"\n# Both YAML and JSON are supported\nopenapi: 3.1.0\ninfo:\n title: Webhook Example\n version: 1.0.0\n# Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\nwebhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n\ncomponents:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n\"\n), options=...)" }, { "label": "Python (Async)", "lang": "Python", - "source": "event_type_import_open_api_out = await svix.event_type.import_openapi(EventTypeImportOpenApiIn(\n spec={\"info\": {\"title\": \"Webhook Example\", \"version\": \"1.0.0\"}, \"openapi\": \"3.1.0\", \"webhooks\": {\"pet.new\": {\"post\": {\"requestBody\": {\"content\": {\"application/json\": {\"schema\": {\"properties\": {\"id\": {\"format\": \"int64\", \"type\": \"integer\"}, \"name\": {\"type\": \"string\"}, \"tag\": {\"type\": \"string\"}}, \"required\": [\"id\", \"name\"]}}}, \"description\": \"Information about a new pet in the system\"}, \"responses\": {\"200\": {\"description\": \"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n spec_raw={\"info\": {\"title\": \"Webhook Example\", \"version\": \"1.0.0\"}, \"openapi\": \"3.1.0\", \"webhooks\": {\"pet.new\": {\"post\": {\"requestBody\": {\"content\": {\"application/json\": {\"schema\": {\"properties\": {\"id\": {\"format\": \"int64\", \"type\": \"integer\"}, \"name\": {\"type\": \"string\"}, \"tag\": {\"type\": \"string\"}}, \"required\": [\"id\", \"name\"]}}}, \"description\": \"Information about a new pet in the system\"}, \"responses\": {\"200\": {\"description\": \"Return a 200 status to indicate that the data was received successfully\"}}}}}}\n), options=...)" + "source": "event_type_import_open_api_out = await svix.event_type.import_openapi(EventTypeImportOpenApiIn(\n spec={\"info\": {\"title\": \"Webhook Example\", \"version\": \"1.0.0\"}, \"openapi\": \"3.1.0\", \"webhooks\": {\"pet.new\": {\"post\": {\"requestBody\": {\"content\": {\"application/json\": {\"schema\": {\"properties\": {\"id\": {\"format\": \"int64\", \"type\": \"integer\"}, \"name\": {\"type\": \"string\"}, \"tag\": {\"type\": \"string\"}}, \"required\": [\"id\", \"name\"]}}}, \"description\": \"Information about a new pet in the system\"}, \"responses\": {\"200\": {\"description\": \"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n spec_raw=\"\n# Both YAML and JSON are supported\nopenapi: 3.1.0\ninfo:\n title: Webhook Example\n version: 1.0.0\n# Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\nwebhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n\ncomponents:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n\"\n), options=...)" }, { "label": "Go", "lang": "Go", - "source": "eventTypeImportOpenApiOut, err := svixClient.EventType.ImportOpenapi(ctx, &EventTypeImportOpenApiIn{\n Spec: map[interface{}]interface{}{\"info\": map[string]interface{}{\"title\": \"Webhook Example\", \"version\": \"1.0.0\"}, \"openapi\": \"3.1.0\", \"webhooks\": map[interface{}]interface{}{\"pet.new\": map[interface{}]interface{}{\"post\": map[interface{}]interface{}{\"requestBody\": map[interface{}]interface{}{\"content\": map[interface{}]interface{}{\"application/json\": map[interface{}]interface{}{\"schema\": map[interface{}]interface{}{\"properties\": map[interface{}]interface{}{\"id\": map[string]interface{}{\"format\": \"int64\", \"type\": \"integer\"}, \"name\": map[string]interface{}{\"type\": \"string\"}, \"tag\": map[string]interface{}{\"type\": \"string\"}}, \"required\": []string{\"id\", \"name\"}}}}, \"description\": \"Information about a new pet in the system\"}, \"responses\": map[interface{}]interface{}{\"200\": map[string]interface{}{\"description\": \"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n SpecRaw: map[interface{}]interface{}{\"info\": map[string]interface{}{\"title\": \"Webhook Example\", \"version\": \"1.0.0\"}, \"openapi\": \"3.1.0\", \"webhooks\": map[interface{}]interface{}{\"pet.new\": map[interface{}]interface{}{\"post\": map[interface{}]interface{}{\"requestBody\": map[interface{}]interface{}{\"content\": map[interface{}]interface{}{\"application/json\": map[interface{}]interface{}{\"schema\": map[interface{}]interface{}{\"properties\": map[interface{}]interface{}{\"id\": map[string]interface{}{\"format\": \"int64\", \"type\": \"integer\"}, \"name\": map[string]interface{}{\"type\": \"string\"}, \"tag\": map[string]interface{}{\"type\": \"string\"}}, \"required\": []string{\"id\", \"name\"}}}}, \"description\": \"Information about a new pet in the system\"}, \"responses\": map[interface{}]interface{}{\"200\": map[string]interface{}{\"description\": \"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n})" + "source": "eventTypeImportOpenApiOut, err := svixClient.EventType.ImportOpenapi(ctx, &EventTypeImportOpenApiIn{\n Spec: map[interface{}]interface{}{\"info\": map[string]interface{}{\"title\": \"Webhook Example\", \"version\": \"1.0.0\"}, \"openapi\": \"3.1.0\", \"webhooks\": map[interface{}]interface{}{\"pet.new\": map[interface{}]interface{}{\"post\": map[interface{}]interface{}{\"requestBody\": map[interface{}]interface{}{\"content\": map[interface{}]interface{}{\"application/json\": map[interface{}]interface{}{\"schema\": map[interface{}]interface{}{\"properties\": map[interface{}]interface{}{\"id\": map[string]interface{}{\"format\": \"int64\", \"type\": \"integer\"}, \"name\": map[string]interface{}{\"type\": \"string\"}, \"tag\": map[string]interface{}{\"type\": \"string\"}}, \"required\": []string{\"id\", \"name\"}}}}, \"description\": \"Information about a new pet in the system\"}, \"responses\": map[interface{}]interface{}{\"200\": map[string]interface{}{\"description\": \"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n SpecRaw: \"\n# Both YAML and JSON are supported\nopenapi: 3.1.0\ninfo:\n title: Webhook Example\n version: 1.0.0\n# Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\nwebhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n\ncomponents:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n\",\n})" }, { "label": "Kotlin", "lang": "Kotlin", - "source": "val eventTypeImportOpenApiOut = svix.eventType.importOpenapi(EventTypeImportOpenApiIn()\n .spec(/* ... */)\n .specRaw(/* ... */)\n)" + "source": "val eventTypeImportOpenApiOut = svix.eventType.importOpenapi(EventTypeImportOpenApiIn()\n .spec(/* ... */)\n .specRaw(\"\n# Both YAML and JSON are supported\nopenapi: 3.1.0\ninfo:\n title: Webhook Example\n version: 1.0.0\n# Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\nwebhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n\ncomponents:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n\")\n)" }, { "label": "Java", "lang": "Java", - "source": "EventTypeImportOpenApiOut eventTypeImportOpenApiOut = svix.getEventType().importOpenapi(new EventTypeImportOpenApiIn()\n .spec(/* ... */)\n .specRaw(/* ... */)\n);" + "source": "EventTypeImportOpenApiOut eventTypeImportOpenApiOut = svix.getEventType().importOpenapi(new EventTypeImportOpenApiIn()\n .spec(/* ... */)\n .specRaw(\"\n# Both YAML and JSON are supported\nopenapi: 3.1.0\ninfo:\n title: Webhook Example\n version: 1.0.0\n# Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\nwebhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n\ncomponents:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n\")\n);" }, { "label": "Ruby", "lang": "Ruby", - "source": "event_type_import_open_api_out = svix.event_type.import_openapi(Svix::EventTypeImportOpenApiIn.new({\n \"spec\": {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n \"spec_raw\": {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}}\n}))" + "source": "event_type_import_open_api_out = svix.event_type.import_openapi(Svix::EventTypeImportOpenApiIn.new({\n \"spec\": {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n \"spec_raw\": \"\n# Both YAML and JSON are supported\nopenapi: 3.1.0\ninfo:\n title: Webhook Example\n version: 1.0.0\n# Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\nwebhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n\ncomponents:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n\"\n}))" }, { "label": "Rust", "lang": "Rust", - "source": "let event_type_import_open_api_out = svix.event_type().import_openapi(EventTypeImportOpenApiIn {\n spec: Some(json!({\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}})),\n spec_raw: Some(json!({\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}})),\n}, None).await?;" + "source": "let event_type_import_open_api_out = svix.event_type().import_openapi(EventTypeImportOpenApiIn {\n spec: Some(json!({\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}})),\n spec_raw: Some(\"\n# Both YAML and JSON are supported\nopenapi: 3.1.0\ninfo:\n title: Webhook Example\n version: 1.0.0\n# Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\nwebhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n\ncomponents:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n\".to_string()),\n}, None).await?;" }, { "label": "C#", "lang": "C#", - "source": "var eventTypeImportOpenApiOut = await svix.EventType.ImportOpenapiAsync(new EventTypeImportOpenApiIn{\n spec: /* ... */,\n specRaw: /* ... */\n});" + "source": "var eventTypeImportOpenApiOut = await svix.EventType.ImportOpenapiAsync(new EventTypeImportOpenApiIn{\n spec: /* ... */,\n specRaw: \"\n# Both YAML and JSON are supported\nopenapi: 3.1.0\ninfo:\n title: Webhook Example\n version: 1.0.0\n# Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\nwebhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n\ncomponents:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n\"\n});" }, { "label": "CLI", "lang": "Shell", - "source": "svix event-type import-openapi '{\n \"spec\": {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n \"specRaw\": {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}}\n}'" + "source": "svix event-type import-openapi '{\n \"spec\": {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n \"specRaw\": \"\n# Both YAML and JSON are supported\nopenapi: 3.1.0\ninfo:\n title: Webhook Example\n version: 1.0.0\n# Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\nwebhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n\ncomponents:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n\"\n}'" }, { "label": "cURL", "lang": "Shell", - "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/event-type/import/openapi' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"spec\": {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n \"specRaw\": {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}}\n }'" + "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/event-type/import/openapi' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"spec\": {\"info\":{\"title\":\"Webhook Example\",\"version\":\"1.0.0\"},\"openapi\":\"3.1.0\",\"webhooks\":{\"pet.new\":{\"post\":{\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"properties\":{\"id\":{\"format\":\"int64\",\"type\":\"integer\"},\"name\":{\"type\":\"string\"},\"tag\":{\"type\":\"string\"}},\"required\":[\"id\",\"name\"]}}},\"description\":\"Information about a new pet in the system\"},\"responses\":{\"200\":{\"description\":\"Return a 200 status to indicate that the data was received successfully\"}}}}}},\n \"specRaw\": \"\n # Both YAML and JSON are supported\n openapi: 3.1.0\n info:\n title: Webhook Example\n version: 1.0.0\n # Since OAS 3.1.0 the paths element isn't necessary. Now a valid OpenAPI Document can describe only paths, webhooks, or even only reusable components\n webhooks:\n # Each webhook needs a name\n \"pet.new\":\n # This is a Path Item Object, the only difference is that the request is initiated by the API provider\n post:\n requestBody:\n description: Information about a new pet in the system\n content:\n application/json:\n schema:\n $ref: \"#/components/schemas/Pet\"\n responses:\n \"200\":\n description: Return a 200 status to indicate that the data was received successfully\n \n components:\n schemas:\n Pet:\n required:\n - id\n - name\n properties:\n id:\n type: integer\n format: int64\n name:\n type: string\n tag:\n type: string\n \"\n }'" } ] } @@ -23101,7 +23253,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/event-type/schema/generate-example' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"schema\": {\"description\":\"An invoice was paid by a user\",\"properties\":{\"invoiceId\":{\"description\":\"The invoice id\",\"type\":\"string\"},\"userId\":{\"description\":\"The user id\",\"type\":\"string\"}},\"required\":[\"invoiceId\",\"userId\"],\"title\":\"Invoice Paid Event\",\"type\":\"object\"}\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/event-type/{event_type_name}": { @@ -24004,7 +24157,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/event-type/{event_type_name}/retry-schedule' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "put": { "description": "Sets a retry schedule for all messages using the given event type.", @@ -24187,7 +24341,8 @@ "lang": "Shell", "source": "curl -X 'PUT' \\\n 'https://api.eu.svix.com/api/v1/event-type/{event_type_name}/retry-schedule' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"retrySchedule\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/events": { @@ -24364,7 +24519,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/events' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/health": { @@ -24581,7 +24737,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/msg/broadcast' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"eventId\": \"unique-msg-identifier\",\n \"eventType\": \"user.signup\",\n \"payload\": {\"email\":\"test@example.com\",\"type\":\"user.created\",\"username\":\"test_user\"},\n \"channels\": [\"project_123\", \"group_2\"],\n \"payloadRetentionPeriod\": 90,\n \"payloadRetentionHours\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/operational-webhook/endpoint": { @@ -25905,7 +26062,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/stats/app/{app_id}/attempt' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/stats/app/{app_id}/ep/{endpoint_id}/attempt": { @@ -26120,7 +26278,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/stats/app/{app_id}/ep/{endpoint_id}/attempt' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true } }, "/api/v1/stats/usage/app": { @@ -26604,7 +26763,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/stream' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "post": { "description": "Creates a new stream.", @@ -26737,7 +26897,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/stream' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"uid\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/stream/event-type": { @@ -26881,7 +27042,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/stream/event-type' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "post": { "description": "Create an event type for Streams.", @@ -27004,7 +27166,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/stream/event-type' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"name\": \"user.signup\",\n \"description\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/stream/event-type/{name}": { @@ -27117,7 +27280,8 @@ "lang": "Shell", "source": "curl -X 'DELETE' \\\n 'https://api.eu.svix.com/api/v1/stream/event-type/{name}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "get": { "description": "Get an event type.", @@ -27235,7 +27399,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/stream/event-type/{name}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "patch": { "description": "Patch an event type for Streams.", @@ -27363,7 +27528,8 @@ "lang": "Shell", "source": "curl -X 'PATCH' \\\n 'https://api.eu.svix.com/api/v1/stream/event-type/{name}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"name\": \"user.signup\",\n \"description\": null\n }'" } - ] + ], + "x-hidden": true }, "put": { "description": "Update or create a event type for Streams.", @@ -27501,7 +27667,8 @@ "lang": "Shell", "source": "curl -X 'PUT' \\\n 'https://api.eu.svix.com/api/v1/stream/event-type/{name}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"name\": \"user.signup\",\n \"description\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/stream/{stream_id}": { @@ -27609,7 +27776,8 @@ "lang": "Shell", "source": "curl -X 'DELETE' \\\n 'https://api.eu.svix.com/api/v1/stream/{stream_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "get": { "description": "Get a stream by id or uid.", @@ -27722,7 +27890,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/stream/{stream_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "patch": { "description": "Partially update a stream.", @@ -27845,7 +28014,8 @@ "lang": "Shell", "source": "curl -X 'PATCH' \\\n 'https://api.eu.svix.com/api/v1/stream/{stream_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"uid\": null\n }'" } - ] + ], + "x-hidden": true }, "put": { "description": "Update a stream.", @@ -27978,7 +28148,8 @@ "lang": "Shell", "source": "curl -X 'PUT' \\\n 'https://api.eu.svix.com/api/v1/stream/{stream_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"uid\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/stream/{stream_id}/events": { @@ -28127,7 +28298,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/stream/{stream_id}/events' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "post": { "description": "Creates events on the Stream.", @@ -28259,7 +28431,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/stream/{stream_id}/events' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"stream\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/transformation-template": { @@ -28455,7 +28628,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/transformation-template' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "post": { "description": "Create a new transformation template.", @@ -28475,7 +28649,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/TemplateIn" + "$ref": "#/components/schemas/ConnectorIn" } } }, @@ -28586,42 +28760,42 @@ { "label": "Python", "lang": "Python", - "source": "template_out = svix.transformation_template.create(TemplateIn(\n instructions_link=None,\n filter_types=[\"user.signup\", \"user.deleted\"],\n feature_flag=\"cool-new-feature\"\n), options=...)" + "source": "template_out = svix.transformation_template.create(ConnectorIn(\n instructions_link=None,\n filter_types=[\"user.signup\", \"user.deleted\"],\n feature_flag=\"cool-new-feature\"\n), options=...)" }, { "label": "Python (Async)", "lang": "Python", - "source": "template_out = await svix.transformation_template.create(TemplateIn(\n instructions_link=None,\n filter_types=[\"user.signup\", \"user.deleted\"],\n feature_flag=\"cool-new-feature\"\n), options=...)" + "source": "template_out = await svix.transformation_template.create(ConnectorIn(\n instructions_link=None,\n filter_types=[\"user.signup\", \"user.deleted\"],\n feature_flag=\"cool-new-feature\"\n), options=...)" }, { "label": "Go", "lang": "Go", - "source": "templateOut, err := svixClient.TransformationTemplate.Create(ctx, &TemplateIn{\n InstructionsLink: nil,\n FilterTypes: []string{\"user.signup\", \"user.deleted\"},\n FeatureFlag: \"cool-new-feature\",\n})" + "source": "templateOut, err := svixClient.TransformationTemplate.Create(ctx, &ConnectorIn{\n InstructionsLink: nil,\n FilterTypes: []string{\"user.signup\", \"user.deleted\"},\n FeatureFlag: \"cool-new-feature\",\n})" }, { "label": "Kotlin", "lang": "Kotlin", - "source": "val templateOut = svix.transformationTemplate.create(TemplateIn()\n .instructionsLink(null)\n .filterTypes(arrayOf(\"user.signup\", \"user.deleted\"))\n .featureFlag(\"cool-new-feature\")\n)" + "source": "val templateOut = svix.transformationTemplate.create(ConnectorIn()\n .instructionsLink(null)\n .filterTypes(arrayOf(\"user.signup\", \"user.deleted\"))\n .featureFlag(\"cool-new-feature\")\n)" }, { "label": "Java", "lang": "Java", - "source": "TemplateOut templateOut = svix.getTransformationTemplate().create(new TemplateIn()\n .instructionsLink(null)\n .filterTypes(new String[]{\"user.signup\", \"user.deleted\"})\n .featureFlag(\"cool-new-feature\")\n);" + "source": "TemplateOut templateOut = svix.getTransformationTemplate().create(new ConnectorIn()\n .instructionsLink(null)\n .filterTypes(new String[]{\"user.signup\", \"user.deleted\"})\n .featureFlag(\"cool-new-feature\")\n);" }, { "label": "Ruby", "lang": "Ruby", - "source": "template_out = svix.transformation_template.create(Svix::TemplateIn.new({\n \"instructions_link\": nil,\n \"filter_types\": [\"user.signup\", \"user.deleted\"],\n \"feature_flag\": \"cool-new-feature\"\n}))" + "source": "template_out = svix.transformation_template.create(Svix::ConnectorIn.new({\n \"instructions_link\": nil,\n \"filter_types\": [\"user.signup\", \"user.deleted\"],\n \"feature_flag\": \"cool-new-feature\"\n}))" }, { "label": "Rust", "lang": "Rust", - "source": "let template_out = svix.transformation_template().create(TemplateIn {\n instructions_link: None,\n filter_types: Some(vec![\"user.signup\".to_string(), \"user.deleted\".to_string()]),\n feature_flag: Some(\"cool-new-feature\".to_string()),\n}, None).await?;" + "source": "let template_out = svix.transformation_template().create(ConnectorIn {\n instructions_link: None,\n filter_types: Some(vec![\"user.signup\".to_string(), \"user.deleted\".to_string()]),\n feature_flag: Some(\"cool-new-feature\".to_string()),\n}, None).await?;" }, { "label": "C#", "lang": "C#", - "source": "var templateOut = await svix.TransformationTemplate.CreateAsync(new TemplateIn{\n instructionsLink: null,\n filterTypes: new string[] {\"user.signup\", \"user.deleted\"},\n featureFlag: \"cool-new-feature\"\n});" + "source": "var templateOut = await svix.TransformationTemplate.CreateAsync(new ConnectorIn{\n instructionsLink: null,\n filterTypes: new string[] {\"user.signup\", \"user.deleted\"},\n featureFlag: \"cool-new-feature\"\n});" }, { "label": "CLI", @@ -28633,7 +28807,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/transformation-template' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"instructionsLink\": null,\n \"filterTypes\": [\"user.signup\", \"user.deleted\"],\n \"featureFlag\": \"cool-new-feature\"\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/transformation-template/generate": { @@ -28813,7 +28988,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/transformation-template/generate' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/transformation-template/oauth/discord": { @@ -28938,7 +29114,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/transformation-template/oauth/discord' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/transformation-template/oauth/hubspot": { @@ -29063,7 +29240,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/transformation-template/oauth/hubspot' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/transformation-template/oauth/slack": { @@ -29188,7 +29366,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/transformation-template/oauth/slack' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/transformation-template/simulate": { @@ -29368,7 +29547,8 @@ "lang": "Shell", "source": "curl -X 'POST' \\\n 'https://api.eu.svix.com/api/v1/transformation-template/simulate' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"eventType\": \"user.signup\",\n \"channels\": null\n }'" } - ] + ], + "x-hidden": true } }, "/api/v1/transformation-template/{transformation_template_id}": { @@ -29531,7 +29711,8 @@ "lang": "Shell", "source": "curl -X 'DELETE' \\\n 'https://api.eu.svix.com/api/v1/transformation-template/{transformation_template_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "get": { "description": "Get a transformation template.", @@ -29699,7 +29880,8 @@ "lang": "Shell", "source": "curl -X 'GET' \\\n 'https://api.eu.svix.com/api/v1/transformation-template/{transformation_template_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n" } - ] + ], + "x-hidden": true }, "patch": { "description": "Partially update a transformation template.", @@ -29877,7 +30059,8 @@ "lang": "Shell", "source": "curl -X 'PATCH' \\\n 'https://api.eu.svix.com/api/v1/transformation-template/{transformation_template_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"instructionsLink\": null,\n \"filterTypes\": [\"user.signup\", \"user.deleted\"],\n \"featureFlag\": \"cool-new-feature\"\n }'" } - ] + ], + "x-hidden": true }, "put": { "description": "Update a transformation template.", @@ -30065,7 +30248,8 @@ "lang": "Shell", "source": "curl -X 'PUT' \\\n 'https://api.eu.svix.com/api/v1/transformation-template/{transformation_template_id}' \\\n -H 'Authorization: Bearer AUTH_TOKEN' \\\n -H 'Accept: application/json' \\\n -H 'Content-Type: application/json'\n \\\n -d '{\n \"instructionsLink\": null,\n \"filterTypes\": [\"user.signup\", \"user.deleted\"],\n \"featureFlag\": \"cool-new-feature\"\n }'" } - ] + ], + "x-hidden": true } } },