Documentation
¶
Index ¶
- type APIKey
- type APIKeyByIDResponse
- type APIKeyResponse
- type Application
- type Configuration
- type ConfigurationResponse
- type CreateAppApiKey
- type CreateGroupResponse
- type DashboardSummary
- type DeliveryAttempt
- type Endpoint
- type Event
- type ForgotPassword
- type Group
- type IDs
- type LoginUser
- type LoginUserResponse
- type MessageResponse
- type Organisation
- type OrganisationInvite
- type PersonalAPIKey
- type PortalAPIKeyResponse
- type RegisterUser
- type ResetPassword
- type RetryConfiguration
- type Role
- type Source
- type SourceResponse
- type Subscription
- type Token
- type UpdateApplication
- type UpdateGroup
- type UpdateOrganisationMember
- type UpdatePassword
- type UpdateSource
- type UpdateSubscription
- type UpdateUser
- type User
- type UserExists
- type UserInviteTokenResponse
- type WebhookRequest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIKeyByIDResponse ¶
type APIKeyByIDResponse struct {
UID string `json:"uid"`
Name string `json:"name"`
Role auth.Role `json:"role"`
Type datastore.KeyType `json:"key_type"`
ExpiresAt primitive.DateTime `json:"expires_at,omitempty"`
CreatedAt primitive.DateTime `json:"created_at,omitempty"`
UpdatedAt primitive.DateTime `json:"updated_at,omitempty"`
DeletedAt primitive.DateTime `json:"deleted_at,omitempty"`
}
type APIKeyResponse ¶
type Application ¶
type Application struct {
AppName string `json:"name" bson:"name" valid:"required~please provide your appName"`
SupportEmail string `json:"support_email" bson:"support_email" valid:"email~please provide a valid email"`
IsDisabled bool `json:"is_disabled"`
SlackWebhookURL string `json:"slack_webhook_url" bson:"slack_webhook_url"`
}
type Configuration ¶ added in v0.6.0
type Configuration struct {
IsAnalyticsEnabled *bool `json:"is_analytics_enabled"`
IsSignupEnabled *bool `json:"is_signup_enabled"`
StoragePolicy *datastore.StoragePolicyConfiguration `json:"storage_policy"`
}
type ConfigurationResponse ¶ added in v0.6.0
type ConfigurationResponse struct {
UID string `json:"uid"`
IsAnalyticsEnabled bool `json:"is_analytics_enabled"`
IsSignupEnabled bool `json:"is_signup_enabled"`
ApiVersion string `json:"api_version"`
StoragePolicy *datastore.StoragePolicyConfiguration `json:"storage_policy"`
CreatedAt primitive.DateTime `json:"created_at,omitempty"`
UpdatedAt primitive.DateTime `json:"updated_at,omitempty"`
DeletedAt primitive.DateTime `json:"deleted_at,omitempty"`
}
type CreateAppApiKey ¶ added in v0.7.0
type CreateGroupResponse ¶ added in v0.6.0
type CreateGroupResponse struct {
APIKey *APIKeyResponse `json:"api_key"`
Group *datastore.Group `json:"group"`
}
type DashboardSummary ¶
type DashboardSummary struct {
EventsSent uint64 `json:"events_sent" bson:"events_sent"`
Applications int `json:"apps" bson:"apps"`
Period string `json:"period" bson:"period"`
PeriodData *[]datastore.EventInterval `json:"event_data,omitempty" bson:"event_data"`
}
type DeliveryAttempt ¶
type DeliveryAttempt struct {
MessageID string `json:"msg_id" bson:"msg_id"`
APIVersion string `json:"api_version" bson:"api_version"`
IPAddress string `json:"ip" bson:"ip"`
Status string `json:"status" bson:"status"`
CreatedAt int64 `json:"created_at" bson:"created_at"`
MessageResponse MessageResponse `json:"response" bson:"response"`
}
type Endpoint ¶
type Endpoint struct {
URL string `json:"url" bson:"url"`
Secret string `json:"secret" bson:"secret"`
Description string `json:"description" bson:"description"`
Events []string `json:"events" bson:"events"`
HttpTimeout string `json:"http_timeout" bson:"http_timeout"`
RateLimit int `json:"rate_limit" bson:"rate_limit"`
RateLimitDuration string `json:"rate_limit_duration" bson:"rate_limit_duration"`
Authentication *datastore.EndpointAuthentication `json:"authentication"`
}
type Event ¶
type Event struct {
AppID string `json:"app_id" bson:"app_id" valid:"required~please provide an app id"`
EventType string `json:"event_type" bson:"event_type" valid:"required~please provide an event type"`
// Data is an arbitrary JSON value that gets sent as the body of the
// webhook to the endpoints
Data json.RawMessage `json:"data" bson:"data" valid:"required~please provide your data"`
CustomHeaders map[string]string `json:"custom_headers"`
}
type ForgotPassword ¶ added in v0.6.0
type ForgotPassword struct {
Email string `json:"email" valid:"required~please provide an email,email"`
}
type Group ¶
type Group struct {
Name string `json:"name" bson:"name" valid:"required~please provide a valid name"`
Type datastore.GroupType `json:"type" bson:"type" valid:"required~please provide a valid type,in(incoming|outgoing)"`
LogoURL string `json:"logo_url" bson:"logo_url" valid:"url~please provide a valid logo url,optional"`
RateLimit int `json:"rate_limit" bson:"rate_limit" valid:"int~please provide a valid rate limit,optional"`
RateLimitDuration string `json:"rate_limit_duration" bson:"rate_limit_duration" valid:"alphanum~please provide a valid rate limit duration,optional"`
Config *datastore.GroupConfig `json:"config"`
}
type LoginUserResponse ¶ added in v0.6.0
type LoginUserResponse struct {
UID string `json:"uid"`
FirstName string `json:"first_name"`
LastName string `json:"last_name"`
Email string `json:"email"`
Token Token `json:"token"`
CreatedAt primitive.DateTime `json:"created_at,omitempty" bson:"created_at"`
UpdatedAt primitive.DateTime `json:"updated_at,omitempty" bson:"updated_at"`
DeletedAt primitive.DateTime `json:"deleted_at,omitempty" bson:"deleted_at"`
}
type MessageResponse ¶
type MessageResponse struct {
Status int `json:"status" bson:"status"`
Data json.RawMessage `json:"data" bson:"data"`
}
type Organisation ¶ added in v0.1.0
type Organisation struct {
Name string `json:"name" bson:"name" valid:"required~please provide a valid name"`
}
type OrganisationInvite ¶ added in v0.6.0
type PersonalAPIKey ¶ added in v0.7.0
type PortalAPIKeyResponse ¶ added in v0.4.10
type RegisterUser ¶ added in v0.6.5
type RegisterUser struct {
FirstName string `json:"first_name" valid:"required~please provide a first name"`
LastName string `json:"last_name" valid:"required~please provide a last name"`
Email string `json:"email" valid:"required~please provide an email,email"`
Password string `json:"password" valid:"required~please provide a password"`
OrganisationName string `json:"org_name" valid:"required~please provide an organisation name"`
}
type ResetPassword ¶ added in v0.6.0
type RetryConfiguration ¶ added in v0.7.0
type RetryConfiguration struct {
Type datastore.StrategyProvider `json:"type,omitempty" valid:"supported_retry_strategy~please provide a valid retry strategy type"`
Duration string `json:"duration,omitempty" valid:"duration~please provide a valid time duration"`
IntervalSeconds uint64 `json:"interval_seconds" valid:"int~please provide a valid interval seconds"`
RetryCount uint64 `json:"retry_count" valid:"int~please provide a valid retry count"`
}
type Source ¶ added in v0.6.0
type Source struct {
Name string `json:"name" valid:"required~please provide a source name"`
Type datastore.SourceType `json:"type" valid:"required~please provide a type,supported_source~unsupported source type"`
Provider datastore.SourceProvider `json:"provider"`
IsDisabled bool `json:"is_disabled"`
Verifier datastore.VerifierConfig `json:"verifier" valid:"required~please provide a verifier"`
}
type SourceResponse ¶ added in v0.6.0
type SourceResponse struct {
UID string `json:"uid"`
MaskID string `json:"mask_id"`
GroupID string `json:"group_id"`
Name string `json:"name"`
Type datastore.SourceType `json:"type"`
URL string `json:"url"`
IsDisabled bool `json:"is_disabled"`
Verifier *datastore.VerifierConfig `json:"verifier"`
Provider datastore.SourceProvider `json:"provider"`
ProviderConfig *datastore.ProviderConfig `json:"provider_config"`
CreatedAt primitive.DateTime `json:"created_at,omitempty"`
UpdatedAt primitive.DateTime `json:"updated_at,omitempty"`
DeletedAt primitive.DateTime `json:"deleted_at,omitempty"`
}
type Subscription ¶ added in v0.6.0
type Subscription struct {
Name string `json:"name" bson:"name" valid:"required~please provide a valid subscription name"`
AppID string `json:"app_id" bson:"app_id" valid:"required~please provide a valid app id"`
SourceID string `json:"source_id" bson:"source_id"`
EndpointID string `json:"endpoint_id" bson:"endpoint_id" valid:"required~please provide a valid endpoint id"`
AlertConfig *datastore.AlertConfiguration `json:"alert_config,omitempty" bson:"alert_config,omitempty"`
RetryConfig *RetryConfiguration `json:"retry_config,omitempty" bson:"retry_config,omitempty"`
FilterConfig *datastore.FilterConfiguration `json:"filter_config,omitempty" bson:"filter_config,omitempty"`
RateLimitConfig *datastore.RateLimitConfiguration `json:"rate_limit_config,omitempty" bson:"rate_limit_config,omitempty"`
DisableEndpoint *bool `json:"disable_endpoint" bson:"disable_endpoint"`
}
type UpdateApplication ¶ added in v0.5.0
type UpdateApplication struct {
AppName *string `json:"name" bson:"name" valid:"required~please provide your appName"`
SupportEmail *string `json:"support_email" bson:"support_email" valid:"email~please provide a valid email"`
IsDisabled *bool `json:"is_disabled"`
SlackWebhookURL *string `json:"slack_webhook_url" bson:"slack_webhook_url"`
}
type UpdateGroup ¶ added in v0.6.0
type UpdateGroup struct {
Name string `json:"name" bson:"name" valid:"required~please provide a valid name"`
LogoURL string `json:"logo_url" bson:"logo_url" valid:"url~please provide a valid logo url,optional"`
RateLimit int `json:"rate_limit" bson:"rate_limit" valid:"int~please provide a valid rate limit,optional"`
RateLimitDuration string `json:"rate_limit_duration" bson:"rate_limit_duration" valid:"alphanum~please provide a valid rate limit duration,optional"`
Config *datastore.GroupConfig `json:"config" valid:"optional"`
}
type UpdateOrganisationMember ¶ added in v0.6.0
type UpdatePassword ¶ added in v0.6.0
type UpdatePassword struct {
CurrentPassword string `json:"current_password" valid:"required~please provide the current password"`
Password string `json:"password" valid:"required~please provide the password field"`
PasswordConfirmation string `json:"password_confirmation" valid:"required~please provide the password confirmation field"`
}
type UpdateSource ¶ added in v0.6.0
type UpdateSource struct {
Name *string `json:"name" valid:"required~please provide a source name"`
Type datastore.SourceType `json:"type" valid:"required~please provide a type,supported_source~unsupported source type"`
IsDisabled *bool `json:"is_disabled"`
ForwardHeaders []string `json:"forward_headers"`
Verifier datastore.VerifierConfig `json:"verifier" valid:"required~please provide a verifier"`
}
type UpdateSubscription ¶ added in v0.6.0
type UpdateSubscription struct {
Name string `json:"name,omitempty"`
AppID string `json:"app_id,omitempty"`
SourceID string `json:"source_id,omitempty"`
EndpointID string `json:"endpoint_id,omitempty"`
AlertConfig *datastore.AlertConfiguration `json:"alert_config,omitempty"`
RetryConfig *RetryConfiguration `json:"retry_config,omitempty"`
FilterConfig *datastore.FilterConfiguration `json:"filter_config,omitempty"`
RateLimitConfig *datastore.RateLimitConfiguration `json:"rate_limit_config,omitempty"`
DisableEndpoint *bool `json:"disable_endpoint" bson:"disable_endpoint"`
}
type UpdateUser ¶ added in v0.6.0
type User ¶ added in v0.6.0
type User struct {
FirstName string `json:"first_name" valid:"required~please provide a first name"`
LastName string `json:"last_name" valid:"required~please provide a last name"`
Email string `json:"email" valid:"required~please provide an email,email"`
Password string `json:"password" valid:"required~please provide a password"`
Role auth.Role `json:"role" bson:"role"`
}
type UserExists ¶ added in v0.6.0
type UserExists struct {
Email string `json:"email" valid:"required~please provide an email,email"`
}
type UserInviteTokenResponse ¶ added in v0.6.0
type UserInviteTokenResponse struct {
Token *datastore.OrganisationInvite `json:"token"`
User *datastore.User `json:"user"`
}
type WebhookRequest ¶
type WebhookRequest struct {
Event string `json:"event" bson:"event"`
Data json.RawMessage `json:"data" bson:"data"`
}
Click to show internal directories.
Click to hide internal directories.