Documentation
¶
Index ¶
- Constants
- func BannerThemeNames() []string
- func DefaultBannerPalette() []string
- func DeleteStoredCredentials(ctx context.Context) error
- func Execute(args []string) int
- func GetAPIClient(ctx context.Context) (*api.Client, error)
- func GetAPIClientWithBaseURL(ctx context.Context, baseURL, site string) (*api.Client, error)
- func GetAPIClientWithSite(ctx context.Context, site string) (*api.Client, error)
- func IsProtectedEnvironment(flags *RootFlags) bool
- func RequireSite(ctx context.Context, site string) (string, error)
- func ResolveAuthCredential(ctx context.Context) (auth.Credential, error)
- func ResolveAuthToken(ctx context.Context) (string, error)
- func ResolveAuthTokenForHost(ctx context.Context, baseURL string) (string, error)
- func VersionString() string
- type APICmd
- type APIDeleteCmd
- type APIGetCmd
- type APILegacyCmd
- type APIPatchCmd
- type APIPostCmd
- type APIPutCmd
- type APIRequestFlags
- type AnnouncementsCmd
- type AnnouncementsCreateCmd
- type AnnouncementsDeleteCmd
- type AnnouncementsGetCmd
- type AnnouncementsListCmd
- type AnnouncementsUpdateCmd
- type AppsCmd
- type AppsCodeCmd
- type AppsCodeCreateCmd
- type AppsCodeDeleteCmd
- type AppsCodeGetCmd
- type AppsCodeListCmd
- type AppsCodePullCmd
- type AppsCodeUpdateCmd
- type AppsConfigCmd
- type AppsCreateCmd
- type AppsGetCmd
- type AppsListCmd
- type AppsLogsCmd
- type AppsPushCmd
- type AppsUpdateCmd
- type AuthCmd
- type AuthKeyringCmd
- type AuthKeyringSetCmd
- type AuthKeyringShowCmd
- type AuthLoginCmd
- type AuthLogoutCmd
- type AuthScopesCmd
- type AuthStatusCmd
- type AuthTokenCmd
- type AuthWhoamiCmd
- type BannerTheme
- type BlogPostsCmd
- type BlogPostsCountCmd
- type BlogPostsCreateCmd
- type BlogPostsDeleteCmd
- type BlogPostsGetCmd
- type BlogPostsListCmd
- type BlogPostsUpdateCmd
- type BlogsCmd
- type BlogsCopyCmd
- type BlogsCountCmd
- type BlogsCreateCmd
- type BlogsDeleteCmd
- type BlogsGetCmd
- type BlogsListCmd
- type BlogsUpdateCmd
- type CLI
- type ChannelEntriesCmd
- type ChannelEntriesCopyCmd
- type ChannelEntriesCountCmd
- type ChannelEntriesCreateCmd
- type ChannelEntriesDeleteCmd
- type ChannelEntriesGalleryAddCmd
- type ChannelEntriesGalleryCmd
- type ChannelEntriesGalleryListCmd
- type ChannelEntriesGalleryRemoveCmd
- type ChannelEntriesGalleryReorderCmd
- type ChannelEntriesGallerySetCmd
- type ChannelEntriesGalleryUpdateCmd
- type ChannelEntriesGetCmd
- type ChannelEntriesListCmd
- type ChannelEntriesUpdateCmd
- type ChannelEntriesWatchCmd
- type ChannelsCmd
- type ChannelsCopyCmd
- type ChannelsCreateCmd
- type ChannelsDeleteCmd
- type ChannelsDiffCmd
- type ChannelsEmptyCmd
- type ChannelsFieldsAddCmd
- type ChannelsFieldsApplyCmd
- type ChannelsFieldsCmd
- type ChannelsFieldsDeleteCmd
- type ChannelsFieldsDiffCmd
- type ChannelsFieldsListCmd
- type ChannelsFieldsReplaceCmd
- type ChannelsFieldsUpdateCmd
- type ChannelsGetCmd
- type ChannelsInfoCmd
- type ChannelsListCmd
- type ChannelsTypesCmd
- type CollectionsCmd
- type CollectionsCopyCmd
- type CollectionsCountCmd
- type CollectionsCreateCmd
- type CollectionsDeleteCmd
- type CollectionsGetCmd
- type CollectionsListCmd
- type CollectionsUpdateCmd
- type CommandContract
- type CommandContractArgument
- type CommandContractCommand
- type CommandContractFlag
- type CommandsCmd
- type CompletionCmd
- type ConfigBannerCmd
- type ConfigCmd
- type ConfigGetCmd
- type ConfigListCmd
- type ConfigPathCmd
- type ConfigSetCmd
- type ConfigUnsetCmd
- type CountQueryFlags
- type CouponsCmd
- type CouponsCountCmd
- type CouponsCreateCmd
- type CouponsDeleteCmd
- type CouponsGetCmd
- type CouponsListCmd
- type CouponsUpdateCmd
- type CustomerRolesAddCmd
- type CustomerRolesCmd
- type CustomerRolesListCmd
- type CustomerRolesRemoveCmd
- type CustomerRolesSetCmd
- type CustomersCmd
- type CustomersConfigCmd
- type CustomersConfigCopyCmd
- type CustomersConfigDiffCmd
- type CustomersCopyCmd
- type CustomersCountCmd
- type CustomersCreateCmd
- type CustomersDeleteCmd
- type CustomersFieldsCmd
- type CustomersGetCmd
- type CustomersListCmd
- type CustomersResendConfirmationCmd
- type CustomersResetPasswordCmd
- type CustomersUpdateCmd
- type DomainRegistrationsCmd
- type DomainRegistrationsCountCmd
- type DomainRegistrationsGetCmd
- type DomainRegistrationsListCmd
- type DomainRegistrationsUpdateCmd
- type DomainRegistrationsUpsertCmd
- type DomainsCmd
- type DomainsCreateCmd
- type DomainsDeleteCmd
- type DomainsGetCmd
- type DomainsListCmd
- type DomainsMakePrimaryCmd
- type DomainsUpdateCmd
- type EnvAddCmd
- type EnvCmd
- type EnvListCmd
- type EnvRemoveCmd
- type EventsCmd
- type EventsIngestCmd
- type EventsTrackCmd
- type ExitError
- type FunctionsCmd
- type FunctionsRunCmd
- type InitCmd
- type InternalCompleteCmd
- type JobsCmd
- type JobsListCmd
- type JobsRunCmd
- type MailsCmd
- type MenusCmd
- type MenusCopyCmd
- type MenusCountCmd
- type MenusCreateCmd
- type MenusDeleteCmd
- type MenusGetCmd
- type MenusListCmd
- type MenusUpdateCmd
- type NotificationsCmd
- type NotificationsCopyCmd
- type NotificationsCountCmd
- type NotificationsCreateCmd
- type NotificationsDeleteCmd
- type NotificationsGetCmd
- type NotificationsListCmd
- type NotificationsPullCmd
- type NotificationsPushCmd
- type NotificationsUpdateCmd
- type OrdersArchiveCmd
- type OrdersCancelCmd
- type OrdersCmd
- type OrdersCountCmd
- type OrdersFinishCmd
- type OrdersGetCmd
- type OrdersListCmd
- type OrdersPayCmd
- type OrdersReopenCmd
- type OrdersUpdateCmd
- type PageVersionsCmd
- type PageVersionsGetCmd
- type PageVersionsListCmd
- type PageVersionsRestoreCmd
- type PagesBatchCmd
- type PagesCmd
- type PagesCopyCmd
- type PagesCountCmd
- type PagesCreateCmd
- type PagesDeleteBlockCmd
- type PagesDeleteCmd
- type PagesDraftBatchCmd
- type PagesDraftCmd
- type PagesDraftDiscardCmd
- type PagesDraftGetCmd
- type PagesDraftPreviewURLCmd
- type PagesDraftPublishCmd
- type PagesDraftSaveCmd
- type PagesGetCmd
- type PagesInsertCmd
- type PagesItemsCmd
- type PagesListCmd
- type PagesMoveCmd
- type PagesSchemaCmd
- type PagesSetCmd
- type PagesUpdateCmd
- type ProductAttachmentsCmd
- type ProductAttachmentsCreateCmd
- type ProductAttachmentsDeleteCmd
- type ProductAttachmentsDownloadCmd
- type ProductAttachmentsGetCmd
- type ProductAttachmentsListCmd
- type ProductAttachmentsUpdateCmd
- type ProductsCmd
- type ProductsConfigCmd
- type ProductsConfigCopyCmd
- type ProductsConfigDiffCmd
- type ProductsCopyCmd
- type ProductsCountCmd
- type ProductsCreateCmd
- type ProductsDeleteCmd
- type ProductsFieldsCmd
- type ProductsGetCmd
- type ProductsListCmd
- type ProductsUpdateCmd
- type QueryFlags
- type RealtimeCmd
- type RealtimeGrantCmd
- type RedirectsCmd
- type RedirectsCopyCmd
- type RedirectsCreateCmd
- type RedirectsDeleteCmd
- type RedirectsGetCmd
- type RedirectsListCmd
- type RedirectsUpdateCmd
- type ReleaseCmd
- type ReleasesCmd
- type RolesCmd
- type RolesCopyCmd
- type RolesCreateCmd
- type RolesCustomersAddCmd
- type RolesCustomersCmd
- type RolesCustomersRemoveCmd
- type RolesCustomersSetCmd
- type RolesDeleteCmd
- type RolesGetCmd
- type RolesListCmd
- type RolesUpdateCmd
- type RootFlags
- type SchemaApplyCmd
- type SchemaCmd
- type SchemaPlanCmd
- type SchemaPullCmd
- type SendersCmd
- type SendersCreateCmd
- type SendersGetCmd
- type SendersListCmd
- type SendersVerifyCmd
- type SendersVerifyOwnershipCmd
- type ServerCmd
- type SettingsCmd
- type SettingsConsentCmd
- type SettingsConsentConfigCmd
- type SettingsConsentConfigCopyCmd
- type SettingsConsentConfigGetCmd
- type SettingsConsentConfigReplaceCmd
- type SettingsConsentConfigUpdateCmd
- type SettingsConsentCreateCmd
- type SettingsConsentDeleteCmd
- type SettingsConsentGetCmd
- type SettingsConsentListCmd
- type SettingsConsentUpdateCmd
- type SettingsGetCmd
- type SettingsUpdateCmd
- type ShippingRatesCmd
- type ShippingRatesCreateCmd
- type ShippingRatesDeleteCmd
- type ShippingRatesGetCmd
- type ShippingRatesListCmd
- type ShippingRatesUpdateCmd
- type SitesCmd
- type SitesCopyCmd
- type SitesCountCmd
- type SitesCurrentCmd
- type SitesGetCmd
- type SitesListCmd
- type SitesSettingsCmd
- type ThemeAssetsCmd
- type ThemeAssetsCreateCmd
- type ThemeAssetsDeleteCmd
- type ThemeAssetsGetCmd
- type ThemeAssetsListCmd
- type ThemeCopyCmd
- type ThemeDiffCmd
- type ThemeFilesCmd
- type ThemeFilesDeleteCmd
- type ThemeFilesGetCmd
- type ThemeFilesListCmd
- type ThemeFilesPutCmd
- type ThemeLayoutsCmd
- type ThemeLayoutsCreateCmd
- type ThemeLayoutsDeleteCmd
- type ThemeLayoutsGetCmd
- type ThemeLayoutsListCmd
- type ThemePullCmd
- type ThemePushCmd
- type ThemeSnippetsCmd
- type ThemeSnippetsCreateCmd
- type ThemeSnippetsDeleteCmd
- type ThemeSnippetsGetCmd
- type ThemeSnippetsListCmd
- type ThemeSyncCmd
- type ThemeTemplatesCmd
- type ThemeTemplatesCreateCmd
- type ThemeTemplatesDeleteCmd
- type ThemeTemplatesGetCmd
- type ThemeTemplatesListCmd
- type ThemesCDNRootCmd
- type ThemesCmd
- type ThemesGetCmd
- type ThemesListCmd
- type TranslationsCmd
- type TranslationsCopyCmd
- type TranslationsCountCmd
- type TranslationsCreateCmd
- type TranslationsDeleteCmd
- type TranslationsGetCmd
- type TranslationsListCmd
- type TranslationsUpdateCmd
- type UploadsCmd
- type UploadsCountCmd
- type UploadsCreateCmd
- type UploadsDeleteCmd
- type UploadsDownloadCmd
- type UploadsGetCmd
- type UploadsListCmd
- type WebhooksCmd
- type WebhooksCountCmd
- type WebhooksCreateCmd
- type WebhooksDeleteCmd
- type WebhooksGetCmd
- type WebhooksListCmd
- type WebhooksUpdateCmd
Constants ¶
const ( ExitSuccess = 0 ExitGeneral = 1 ExitUsage = 2 ExitAuth = 3 ExitAuthz = 4 ExitNotFound = 5 ExitValidation = 6 ExitRateLimit = 7 ExitNetwork = 8 )
Exit codes
Variables ¶
This section is empty.
Functions ¶
func BannerThemeNames ¶
func BannerThemeNames() []string
BannerThemeNames returns the names of all available themes.
func DefaultBannerPalette ¶
func DefaultBannerPalette() []string
DefaultBannerPalette returns the default (white) palette.
func DeleteStoredCredentials ¶
func GetAPIClient ¶
GetAPIClient creates an API client from context.
func GetAPIClientWithBaseURL ¶
GetAPIClientWithBaseURL creates an API client with a specific base URL and site.
func GetAPIClientWithSite ¶
GetAPIClientWithSite creates an API client with a specific site.
func IsProtectedEnvironment ¶ added in v0.3.3
IsProtectedEnvironment reports protection for the selected project environment.
func RequireSite ¶
RequireSite ensures a site is specified.
func ResolveAuthCredential ¶
func ResolveAuthCredential(ctx context.Context) (auth.Credential, error)
func ResolveAuthToken ¶
ResolveAuthToken returns a usable bearer token for the session's API host. OAuth sessions are refreshed first when the access token is about to expire.
func ResolveAuthTokenForHost ¶ added in v0.2.3
ResolveAuthTokenForHost resolves the token for the host of baseURL, so cross-host commands (--from-host/--to-host) authenticate against each API with its own stored credential instead of the session default's.
Types ¶
type APICmd ¶
type APICmd struct {
Get APIGetCmd `cmd:"" aliases:"GET" help:"Send a GET request"`
Post APIPostCmd `cmd:"" aliases:"POST" help:"Send a POST request"`
Put APIPutCmd `cmd:"" aliases:"PUT" help:"Send a PUT request"`
Patch APIPatchCmd `cmd:"" aliases:"PATCH" help:"Send a PATCH request"`
Delete APIDeleteCmd `cmd:"" aliases:"DELETE" help:"Send a DELETE request (requires --force)"`
Legacy APILegacyCmd `cmd:"" default:"withargs" hidden:""`
}
APICmd provides raw API access. Verb-first commands are canonical; Legacy preserves the original --method/--path interface.
type APIDeleteCmd ¶ added in v0.3.0
type APIDeleteCmd struct {
Path string `arg:"" required:"" help:"API path"`
APIRequestFlags
}
type APIGetCmd ¶ added in v0.3.0
type APIGetCmd struct {
Path string `arg:"" required:"" help:"API path"`
APIRequestFlags
}
type APILegacyCmd ¶ added in v0.3.0
type APILegacyCmd struct {
Method string `required:"" help:"HTTP method (GET, POST, PUT, PATCH, DELETE)"`
Path string `required:"" help:"API path (e.g., /channels)"`
APIRequestFlags
}
type APIPatchCmd ¶ added in v0.3.0
type APIPatchCmd struct {
Path string `arg:"" required:"" help:"API path"`
APIRequestFlags
}
type APIPostCmd ¶ added in v0.3.0
type APIPostCmd struct {
Path string `arg:"" required:"" help:"API path"`
APIRequestFlags
}
type APIPutCmd ¶ added in v0.3.0
type APIPutCmd struct {
Path string `arg:"" required:"" help:"API path"`
APIRequestFlags
}
type APIRequestFlags ¶ added in v0.3.0
type APIRequestFlags struct {
Data string `help:"Request JSON: inline, @file, or - for stdin" short:"d"`
File string `help:"Read request JSON from file (legacy; use --data @file)" type:"existingfile"`
All bool `help:"Fetch every page of a JSON array response"`
Output string `help:"Write an exact binary response to FILE or - for stdout"`
}
type AnnouncementsCmd ¶ added in v0.3.0
type AnnouncementsCmd struct {
List AnnouncementsListCmd `cmd:"" help:"List announcements"`
Get AnnouncementsGetCmd `cmd:"" help:"Get an announcement"`
Create AnnouncementsCreateCmd `cmd:"" help:"Create an announcement"`
Update AnnouncementsUpdateCmd `cmd:"" help:"Update an announcement"`
Delete AnnouncementsDeleteCmd `cmd:"" help:"Delete an announcement (requires --force)"`
}
type AnnouncementsCreateCmd ¶ added in v0.3.0
type AnnouncementsDeleteCmd ¶ added in v0.3.0
type AnnouncementsDeleteCmd struct {
ID string `required:"" help:"Announcement ID"`
}
type AnnouncementsGetCmd ¶ added in v0.3.0
type AnnouncementsGetCmd struct {
ID string `required:"" help:"Announcement ID"`
}
type AnnouncementsListCmd ¶ added in v0.3.0
type AnnouncementsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `default:"1" help:"Page number"`
PerPage int `default:"25" help:"Items per page"`
}
type AnnouncementsUpdateCmd ¶ added in v0.3.0
type AppsCmd ¶
type AppsCmd struct {
List AppsListCmd `cmd:"" help:"List apps"`
Get AppsGetCmd `cmd:"" help:"Get app details"`
Create AppsCreateCmd `cmd:"" help:"Create an app"`
Update AppsUpdateCmd `cmd:"" help:"Update an app"`
Config AppsConfigCmd `cmd:"" help:"Add an app to local project config"`
Push AppsPushCmd `cmd:"" help:"Push configured local cloud-code files"`
Logs AppsLogsCmd `cmd:"" help:"Read app cloud-code logs"`
Code AppsCodeCmd `cmd:"" help:"Manage app cloud code files"`
}
AppsCmd manages OAuth apps.
type AppsCodeCmd ¶
type AppsCodeCmd struct {
List AppsCodeListCmd `cmd:"" help:"List app code files"`
Get AppsCodeGetCmd `cmd:"" help:"Get an app code file"`
Create AppsCodeCreateCmd `cmd:"" help:"Create app code file from JSON"`
Update AppsCodeUpdateCmd `cmd:"" help:"Update an app code file"`
Delete AppsCodeDeleteCmd `cmd:"" help:"Delete an app code file (requires --force)"`
Pull AppsCodePullCmd `cmd:"" help:"Pull remote app code files"`
}
AppsCodeCmd manages app cloud code files.
type AppsCodeCreateCmd ¶
type AppsCodeCreateCmd struct {
App string `required:"" help:"Application ID"`
File string `help:"Read code file JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=main.js, code=console.log(1))"`
}
AppsCodeCreateCmd creates an app code file.
type AppsCodeDeleteCmd ¶ added in v0.3.0
type AppsCodeGetCmd ¶ added in v0.3.0
type AppsCodeListCmd ¶
type AppsCodeListCmd struct {
QueryFlags `embed:""`
App string `required:"" help:"Application ID"`
}
AppsCodeListCmd lists app code files.
type AppsCodePullCmd ¶ added in v0.2.2
type AppsCodePullCmd struct {
App string `help:"Configured local app name"`
Files []string `help:"Remote or project-relative file subset; commas split multiple files" name:"only"`
}
AppsCodePullCmd pulls remote app code files into the configured local app directory.
type AppsCodeUpdateCmd ¶ added in v0.3.0
type AppsConfigCmd ¶
type AppsConfigCmd struct{}
AppsConfigCmd adds an app to the local project config.
type AppsCreateCmd ¶ added in v0.2.6
type AppsCreateCmd struct {
Name string `required:"" help:"App name"`
Description string `help:"App description"`
Internal bool `` /* 128-byte string literal not displayed */
Scopes []string `help:"Install scopes (comma-separated, e.g. read_channels,write_channels); required for internal apps"`
URL string `help:"App URL (external apps only)"`
CallbackURL string `name:"callback-url" help:"OAuth callback URL (external apps only)"`
SDKVersion string `name:"sdk-version" help:"Cloud-code SDK version"`
Install *bool `negatable:"" help:"Grant and register the app on the site in one step (default: true for internal apps)"`
Configure bool `help:"After creating, add the app to the local nimbu.yml project config"`
}
AppsCreateCmd creates an OAuth / cloud-code app.
type AppsGetCmd ¶
type AppsGetCmd struct {
App string `required:"" help:"Application ID"`
}
AppsGetCmd gets an app by ID.
type AppsListCmd ¶
type AppsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
AppsListCmd lists apps.
type AppsLogsCmd ¶ added in v0.2.5
type AppsLogsCmd struct {
App string `required:"" help:"Application local name or key"`
Tail bool `help:"Poll for new logs until interrupted" short:"t"`
Level string `help:"Minimum severity: debug, info, warn, error, fatal"`
Query string `help:"Text search query" short:"q" name:"query"`
Job string `help:"Only logs from this background job name"`
Since string `help:"Only logs after this value; raw epoch/ISO8601 or duration like 15m, 1h, 24h"`
Limit int `help:"Maximum logs to fetch" default:"100"`
}
AppsLogsCmd reads app cloud-code logs.
type AppsPushCmd ¶
type AppsPushCmd struct {
App string `help:"Configured local app name"`
Sync bool `help:"Delete remote files missing locally"`
Files []string `help:"Project-relative file subset; commas split multiple files" name:"only"`
}
AppsPushCmd pushes configured local cloud code files.
type AppsUpdateCmd ¶ added in v0.2.6
type AppsUpdateCmd struct {
App string `required:"" help:"Application ID"`
Name *string `help:"App name"`
Description *string `help:"App description"`
Internal *bool `negatable:"" help:"Whether the app is internal (callback derived from scopes)"`
Scopes []string `help:"Install scopes (comma-separated, e.g. read_channels,write_channels)"`
URL *string `help:"App URL (external apps only)"`
CallbackURL *string `name:"callback-url" help:"OAuth callback URL (external apps only)"`
SDKVersion *string `name:"sdk-version" help:"Cloud-code SDK version"`
}
AppsUpdateCmd updates an existing app. Only the flags you provide are sent.
type AuthCmd ¶
type AuthCmd struct {
Login AuthLoginCmd `cmd:"" help:"Log in to Nimbu"`
Logout AuthLogoutCmd `cmd:"" help:"Log out and remove stored credentials"`
Status AuthStatusCmd `cmd:"" help:"Show authentication status"`
Whoami AuthWhoamiCmd `cmd:"" help:"Show current authenticated user"`
Scopes AuthScopesCmd `cmd:"" help:"Show active token scopes"`
Token AuthTokenCmd `cmd:"" help:"Print access token for scripts"`
Keyring AuthKeyringCmd `cmd:"" help:"Manage keyring backend"`
}
AuthCmd handles authentication commands.
type AuthKeyringCmd ¶
type AuthKeyringCmd struct {
Show AuthKeyringShowCmd `cmd:"" default:"1" help:"Show current keyring backend"`
Set AuthKeyringSetCmd `cmd:"" help:"Set keyring backend"`
}
AuthKeyringCmd manages keyring backend.
type AuthKeyringSetCmd ¶
type AuthKeyringSetCmd struct {
Backend string `required:"" help:"Backend to use: auto, keychain, file, secret-service, kwallet, wincred"`
}
AuthKeyringSetCmd sets the keyring backend.
type AuthKeyringShowCmd ¶
type AuthKeyringShowCmd struct{}
AuthKeyringShowCmd shows the current keyring backend.
type AuthLoginCmd ¶
type AuthLoginCmd struct {
Device bool `help:"Log in with a one-time code entered in a browser on any device (SSH, containers)"`
Scopes string `help:"Comma-separated OAuth scopes to request (default: full CLI access)"`
// Deliberately not bound to NIMBU_TOKEN: an exported CI token must not
// turn a login into storing that token.
Token string `help:"Store an existing API token instead of logging in" short:"t"`
// Deprecated email/password login, kept for scripts. Either flag selects it.
Email string `help:"Deprecated: log in with email and password" short:"e" hidden:""`
Password string `help:"Deprecated: password for --email login" short:"p" hidden:""`
ExpiresIn int `help:"Deprecated: token lifetime in seconds for --email login" short:"x" default:"7776000" hidden:""`
}
AuthLoginCmd logs in to Nimbu.
type AuthLogoutCmd ¶
type AuthLogoutCmd struct{}
AuthLogoutCmd logs out and removes stored credentials.
type AuthScopesCmd ¶
type AuthScopesCmd struct{}
AuthScopesCmd shows active scopes for the current token.
type AuthWhoamiCmd ¶
type AuthWhoamiCmd struct{}
AuthWhoamiCmd shows the current authenticated user.
type BannerTheme ¶
type BannerTheme struct {
Name string
Label string
Palette []string // one hex color per banner line
}
BannerTheme holds a named color palette for the server banner.
func BannerThemeByName ¶
func BannerThemeByName(name string) (BannerTheme, bool)
BannerThemeByName looks up a theme by name (case-insensitive).
func BannerThemes ¶
func BannerThemes() []BannerTheme
BannerThemes returns the ordered list of available themes.
type BlogPostsCmd ¶
type BlogPostsCmd struct {
List BlogPostsListCmd `cmd:"" help:"List blog articles"`
Get BlogPostsGetCmd `cmd:"" help:"Get blog article"`
Create BlogPostsCreateCmd `cmd:"" help:"Create a blog article"`
Update BlogPostsUpdateCmd `cmd:"" help:"Update a blog article"`
Delete BlogPostsDeleteCmd `cmd:"" help:"Delete a blog article"`
Count BlogPostsCountCmd `cmd:"" help:"Count blog articles"`
}
BlogPostsCmd manages blog posts (articles).
type BlogPostsCountCmd ¶
type BlogPostsCountCmd struct {
CountQueryFlags `embed:""`
Blog string `required:"" help:"Blog ID or handle"`
}
BlogPostsCountCmd gets count of articles for a blog.
type BlogPostsCreateCmd ¶
type BlogPostsCreateCmd struct {
Blog string `required:"" help:"Blog ID or handle"`
Locale string `help:"Content locale for localized post fields"`
File string `help:"Read post JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. title=Hello, status=published)"`
}
BlogPostsCreateCmd creates a blog article.
type BlogPostsDeleteCmd ¶
type BlogPostsDeleteCmd struct {
Blog string `required:"" help:"Blog ID or handle"`
Post string `required:"" help:"Post ID or slug"`
}
BlogPostsDeleteCmd deletes a blog article.
type BlogPostsGetCmd ¶
type BlogPostsGetCmd struct {
Blog string `required:"" help:"Blog ID or handle"`
Post string `required:"" help:"Post ID or slug"`
Locale string `help:"Content locale for localized post fields"`
}
BlogPostsGetCmd gets a blog article.
type BlogPostsListCmd ¶
type BlogPostsListCmd struct {
QueryFlags `embed:""`
Blog string `required:"" help:"Blog ID or handle"`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
BlogPostsListCmd lists blog articles.
type BlogPostsUpdateCmd ¶
type BlogPostsUpdateCmd struct {
Blog string `required:"" help:"Blog ID or handle"`
Post string `required:"" help:"Post ID or slug"`
Locale string `help:"Content locale for localized post fields"`
File string `help:"Read post JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. title=Hello, status=published)"`
}
BlogPostsUpdateCmd updates a blog article.
type BlogsCmd ¶
type BlogsCmd struct {
List BlogsListCmd `cmd:"" help:"List blogs"`
Get BlogsGetCmd `cmd:"" help:"Get blog details"`
Create BlogsCreateCmd `cmd:"" help:"Create a blog"`
Update BlogsUpdateCmd `cmd:"" help:"Update a blog"`
Delete BlogsDeleteCmd `cmd:"" help:"Delete a blog"`
Count BlogsCountCmd `cmd:"" help:"Count blogs"`
Posts BlogPostsCmd `cmd:"" help:"Manage blog articles" aliases:"articles"`
Copy BlogsCopyCmd `cmd:"" help:"Copy blogs and posts between sites"`
}
BlogsCmd manages blogs.
type BlogsCopyCmd ¶
type BlogsCopyCmd struct {
Handle string `help:"Blog handle to copy" default:"*" name:"only"`
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
}
BlogsCopyCmd copies blogs and their posts between sites.
type BlogsCountCmd ¶
type BlogsCountCmd struct {
CountQueryFlags `embed:""`
}
BlogsCountCmd gets blog count.
type BlogsCreateCmd ¶
type BlogsCreateCmd struct {
Locale string `help:"Content locale for localized blog fields"`
File string `help:"Read blog JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=Blog, slug=news)"`
}
BlogsCreateCmd creates a blog.
type BlogsDeleteCmd ¶
type BlogsDeleteCmd struct {
Blog string `required:"" help:"Blog ID or handle"`
}
BlogsDeleteCmd deletes a blog.
type BlogsGetCmd ¶
type BlogsGetCmd struct {
Blog string `required:"" help:"Blog ID or handle"`
Locale string `help:"Content locale for localized blog fields"`
}
BlogsGetCmd gets blog details.
type BlogsListCmd ¶
type BlogsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
BlogsListCmd lists blogs.
type BlogsUpdateCmd ¶
type BlogsUpdateCmd struct {
Blog string `required:"" help:"Blog ID or handle"`
Locale string `help:"Content locale for localized blog fields"`
File string `help:"Read blog JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=Blog, slug=news)"`
}
BlogsUpdateCmd updates a blog.
type CLI ¶
type CLI struct {
RootFlags `embed:""`
HelpAll bool `help:"Show all flags including hidden" name:"help-all" hidden:""`
Version kong.VersionFlag `help:"Print version and exit"`
Auth AuthCmd `cmd:"" help:"Authentication and credentials"`
Init InitCmd `cmd:"" help:"Bootstrap a local theme project"`
Sites SitesCmd `cmd:"" help:"Manage sites"`
Schema SchemaCmd `cmd:"" help:"Manage declarative schemas"`
Release ReleaseCmd `cmd:"" help:"Release schema, cloud code and theme"`
Releases ReleasesCmd `cmd:"" help:"List successful releases"`
Channels ChannelsCmd `cmd:"" help:"Manage channels and entries"`
Pages PagesCmd `cmd:"" help:"Manage pages"`
Menus MenusCmd `cmd:"" help:"Manage navigation menus"`
Products ProductsCmd `cmd:"" help:"Manage products"`
ShippingRates ShippingRatesCmd `cmd:"" name:"shipping-rates" help:"Manage shipping rates"`
Collections CollectionsCmd `cmd:"" help:"Manage collections"`
Coupons CouponsCmd `cmd:"" help:"Manage coupons"`
Domains DomainsCmd `cmd:"" help:"Manage custom domains"`
Orders OrdersCmd `cmd:"" help:"Manage orders"`
Customers CustomersCmd `cmd:"" help:"Manage customers"`
Mails MailsCmd `cmd:"" aliases:"mail" help:"Sync notification templates to local files"`
Announcements AnnouncementsCmd `cmd:"" help:"Manage platform announcements"`
DomainRegistrations DomainRegistrationsCmd `cmd:"" name:"domain-registrations" help:"Manage domain registrations"`
Settings SettingsCmd `cmd:"" help:"Manage site settings"`
Events EventsCmd `cmd:"" help:"Track and ingest events"`
Realtime RealtimeCmd `cmd:"" help:"Realtime grants and live queries"`
Notifications NotificationsCmd `cmd:"" help:"Manage notifications"`
Roles RolesCmd `cmd:"" help:"Manage roles"`
Redirects RedirectsCmd `cmd:"" help:"Manage redirects"`
Functions FunctionsCmd `cmd:"" help:"Execute cloud functions"`
Jobs JobsCmd `cmd:"" help:"Execute cloud jobs"`
Apps AppsCmd `cmd:"" help:"Manage OAuth apps"`
Senders SendersCmd `cmd:"" help:"Manage email sender domains"`
Themes ThemesCmd `cmd:"" help:"Manage themes"`
Uploads UploadsCmd `cmd:"" help:"Manage uploads"`
Blogs BlogsCmd `cmd:"" help:"Manage blogs"`
Webhooks WebhooksCmd `cmd:"" help:"Manage webhooks"`
Translations TranslationsCmd `cmd:"" help:"Manage translations"`
Server ServerCmd `cmd:"" help:"Run local simulator proxy with child dev server"`
Env EnvCmd `cmd:"" help:"Manage project environments"`
Config ConfigCmd `cmd:"" help:"Manage configuration"`
API APICmd `cmd:"" help:"Raw API access"`
Commands CommandsCmd `cmd:"" help:"Export the machine-readable command contract"`
Completion CompletionCmd `cmd:"" help:"Generate shell completions"`
Complete InternalCompleteCmd `cmd:"" name:"__complete" hidden:""`
}
CLI is the root command structure.
type ChannelEntriesCmd ¶
type ChannelEntriesCmd struct {
List ChannelEntriesListCmd `cmd:"" help:"List channel entries"`
Get ChannelEntriesGetCmd `cmd:"" help:"Get entry by ID or slug"`
Create ChannelEntriesCreateCmd `cmd:"" help:"Create entry from JSON"`
Update ChannelEntriesUpdateCmd `cmd:"" help:"Update entry"`
Delete ChannelEntriesDeleteCmd `cmd:"" help:"Delete entry"`
Count ChannelEntriesCountCmd `cmd:"" help:"Count entries"`
Copy ChannelEntriesCopyCmd `cmd:"" help:"Copy channel entries between sites"`
Gallery ChannelEntriesGalleryCmd `cmd:"" help:"Manage gallery fields on channel entries"`
Watch ChannelEntriesWatchCmd `cmd:"" help:"Stream live entry events over the realtime socket"`
}
ChannelEntriesCmd manages channel entries.
type ChannelEntriesCopyCmd ¶
type ChannelEntriesCopyCmd struct {
From string `help:"Source site/channel" required:"" name:"from"`
To string `help:"Target site/channel" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
Recursive bool `help:"Recursively copy referenced channel entries"`
Only string `help:"Comma-separated channel allowlist when using --recursive"`
Query string `help:"Raw query string to append to the source entry list"`
Where string `help:"Where expression for source entry selection"`
PerPage int `help:"Items per page" name:"per-page"`
Upsert string `help:"Comma-separated upsert fields, optionally channel-scoped as channel:field"`
CopyCustomers bool `name:"copy-customers" help:"Copy related customers for owners and customer fields"`
AllowErrors bool `name:"allow-errors" help:"Continue on item-level validation errors"`
DryRun bool `name:"dry-run" help:"Reserved for parity; currently reports planned selection only"`
}
ChannelEntriesCopyCmd copies channel entries between sites.
type ChannelEntriesCountCmd ¶
type ChannelEntriesCountCmd struct {
CountQueryFlags `embed:""`
Channel string `required:"" help:"Channel ID or slug"`
}
ChannelEntriesCountCmd counts channel entries.
type ChannelEntriesCreateCmd ¶
type ChannelEntriesCreateCmd struct {
Channel string `required:"" help:"Channel ID or slug"`
Locale string `help:"Content locale for localized channel fields"`
File string `help:"Read entry JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. title=Hello, fields.teaser=Text)"`
}
ChannelEntriesCreateCmd creates a channel entry.
type ChannelEntriesDeleteCmd ¶
type ChannelEntriesDeleteCmd struct {
Channel string `required:"" help:"Channel ID or slug"`
Entry string `required:"" help:"Entry ID or slug"`
}
ChannelEntriesDeleteCmd deletes a channel entry.
type ChannelEntriesGalleryAddCmd ¶ added in v0.2.2
type ChannelEntriesGalleryAddCmd struct {
Channel string `required:"" help:"Channel ID or slug"`
Entry string `required:"" help:"Entry ID or slug"`
Field string `required:"" help:"Gallery field name"`
Images []string `name:"image" help:"Local image path (repeatable)"`
Captions []string `name:"caption" help:"Caption for each image, matched by order"`
Positions []int `name:"position" help:"Position for each image, matched by order"`
Locale string `help:"Content locale for localized channel fields"`
DryRun bool `name:"dry-run" help:"Print the payload without updating the entry"`
}
ChannelEntriesGalleryAddCmd appends gallery images.
type ChannelEntriesGalleryCmd ¶ added in v0.2.2
type ChannelEntriesGalleryCmd struct {
List ChannelEntriesGalleryListCmd `cmd:"" help:"List gallery images"`
Set ChannelEntriesGallerySetCmd `cmd:"" help:"Replace gallery images"`
Add ChannelEntriesGalleryAddCmd `cmd:"" help:"Append gallery images"`
Update ChannelEntriesGalleryUpdateCmd `cmd:"" help:"Update one gallery image"`
Remove ChannelEntriesGalleryRemoveCmd `cmd:"" help:"Remove gallery images"`
Reorder ChannelEntriesGalleryReorderCmd `cmd:"" help:"Reorder gallery images"`
}
ChannelEntriesGalleryCmd manages gallery fields on channel entries.
type ChannelEntriesGalleryListCmd ¶ added in v0.2.2
type ChannelEntriesGalleryListCmd struct {
Channel string `required:"" help:"Channel ID or slug"`
Entry string `required:"" help:"Entry ID or slug"`
Field string `required:"" help:"Gallery field name"`
Locale string `help:"Content locale for localized channel fields"`
}
ChannelEntriesGalleryListCmd lists gallery images.
type ChannelEntriesGalleryRemoveCmd ¶ added in v0.2.2
type ChannelEntriesGalleryRemoveCmd struct {
Channel string `required:"" help:"Channel ID or slug"`
Entry string `required:"" help:"Entry ID or slug"`
Field string `required:"" help:"Gallery field name"`
ImageIDs []string `name:"image-id" required:"" help:"Gallery image ID to remove (repeatable)"`
Locale string `help:"Content locale for localized channel fields"`
DryRun bool `name:"dry-run" help:"Print the payload without updating the entry"`
}
ChannelEntriesGalleryRemoveCmd removes gallery images.
type ChannelEntriesGalleryReorderCmd ¶ added in v0.2.2
type ChannelEntriesGalleryReorderCmd struct {
Channel string `required:"" help:"Channel ID or slug"`
Entry string `required:"" help:"Entry ID or slug"`
Field string `required:"" help:"Gallery field name"`
Order string `required:"" help:"Comma-separated gallery image IDs in desired order"`
Locale string `help:"Content locale for localized channel fields"`
DryRun bool `name:"dry-run" help:"Print the payload without updating the entry"`
}
ChannelEntriesGalleryReorderCmd reorders gallery images.
type ChannelEntriesGallerySetCmd ¶ added in v0.2.2
type ChannelEntriesGallerySetCmd struct {
Channel string `required:"" help:"Channel ID or slug"`
Entry string `required:"" help:"Entry ID or slug"`
Field string `required:"" help:"Gallery field name"`
Images []string `name:"image" help:"Local image path (repeatable)"`
Captions []string `name:"caption" help:"Caption for each image, matched by order"`
Positions []int `name:"position" help:"Position for each image, matched by order"`
Locale string `help:"Content locale for localized channel fields"`
DryRun bool `name:"dry-run" help:"Print the payload without updating the entry"`
}
ChannelEntriesGallerySetCmd replaces gallery images.
type ChannelEntriesGalleryUpdateCmd ¶ added in v0.2.2
type ChannelEntriesGalleryUpdateCmd struct {
Channel string `required:"" help:"Channel ID or slug"`
Entry string `required:"" help:"Entry ID or slug"`
Field string `required:"" help:"Gallery field name"`
ImageID string `name:"image-id" required:"" help:"Gallery image ID"`
Caption *string `help:"Updated caption"`
Position *int `help:"Updated position"`
Image string `name:"image" help:"Replacement local image path"`
Locale string `help:"Content locale for localized channel fields"`
DryRun bool `name:"dry-run" help:"Print the payload without updating the entry"`
}
ChannelEntriesGalleryUpdateCmd updates one gallery image.
type ChannelEntriesGetCmd ¶
type ChannelEntriesGetCmd struct {
QueryFlags `embed:""`
Channel string `required:"" help:"Channel ID or slug"`
Entry string `required:"" help:"Entry ID or slug"`
}
ChannelEntriesGetCmd gets an entry by ID or slug.
func (ChannelEntriesGetCmd) Help ¶ added in v0.3.1
func (ChannelEntriesGetCmd) Help() string
type ChannelEntriesListCmd ¶
type ChannelEntriesListCmd struct {
QueryFlags `embed:""`
Channel string `required:"" help:"Channel ID or slug"`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
ChannelEntriesListCmd lists channel entries.
type ChannelEntriesUpdateCmd ¶
type ChannelEntriesUpdateCmd struct {
Channel string `required:"" help:"Channel ID or slug"`
Entry string `required:"" help:"Entry ID or slug"`
Locale string `` /* 179-byte string literal not displayed */
File string `help:"Read entry JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. title=Hello, fields.teaser=Text)"`
}
ChannelEntriesUpdateCmd updates a channel entry.
type ChannelEntriesWatchCmd ¶ added in v0.3.3
type ChannelEntriesWatchCmd struct {
Channel string `required:"" help:"Channel ID or slug" group:"Query"`
Where string `help:"Filter expression (same syntax as --filters where=...)" group:"Query"`
Filters []string `aliases:"filter" help:"Filter entries by key=value or key.op=value, repeatable" group:"Query"`
Once bool `help:"Exit after the first event"`
For time.Duration `name:"for" help:"Stop watching after this duration, e.g. 30s"`
Host string `help:"Override the site host used for the websocket (e.g. localhost:3000 for dev)"`
Insecure bool `help:"Skip TLS verification for the websocket (dev only)"`
}
ChannelEntriesWatchCmd streams live channel entry events over the realtime socket.
type ChannelsCmd ¶
type ChannelsCmd struct {
List ChannelsListCmd `cmd:"" help:"List channels"`
Get ChannelsGetCmd `cmd:"" help:"Get channel details"`
Create ChannelsCreateCmd `cmd:"" help:"Create a channel from JSON or inline assignments"`
Info ChannelsInfoCmd `cmd:"" help:"Show rich channel info and TypeScript output"`
Types ChannelsTypesCmd `cmd:"" help:"Generate one TypeScript module with the types of all channels"`
Copy ChannelsCopyCmd `cmd:"" help:"Copy channel configuration between sites"`
Diff ChannelsDiffCmd `cmd:"" help:"Diff channel configuration between sites"`
Empty ChannelsEmptyCmd `cmd:"" help:"Empty a channel after strict confirmation"`
Delete ChannelsDeleteCmd `cmd:"" help:"Delete a channel (requires --force)"`
Entries ChannelEntriesCmd `cmd:"" help:"Manage channel entries"`
Fields ChannelsFieldsCmd `cmd:"" help:"Manage channel fields"`
}
ChannelsCmd manages channels.
type ChannelsCopyCmd ¶
type ChannelsCopyCmd struct {
All bool `help:"Copy all channels from source to target"`
From string `help:"Source site/channel or site when using --all" required:"" name:"from"`
To string `help:"Target site/channel or site when using --all" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
}
ChannelsCopyCmd copies one or all channels between sites.
type ChannelsCreateCmd ¶ added in v0.2.3
type ChannelsCreateCmd struct {
File string `help:"Read channel JSON from file (use - for stdin)"`
Assignments []string `` /* 136-byte string literal not displayed */
}
ChannelsCreateCmd creates a channel.
type ChannelsDeleteCmd ¶ added in v0.2.3
type ChannelsDeleteCmd struct {
Channel string `required:"" help:"Channel ID or slug"`
}
ChannelsDeleteCmd deletes a channel.
type ChannelsDiffCmd ¶
type ChannelsDiffCmd struct {
From string `help:"Source site/channel" required:"" name:"from"`
To string `help:"Target site/channel" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
}
ChannelsDiffCmd diffs two channels between sites.
type ChannelsEmptyCmd ¶ added in v0.1.4
type ChannelsFieldsAddCmd ¶ added in v0.1.14
type ChannelsFieldsAddCmd struct {
Channel string `required:"" help:"Channel slug"`
Name string `required:"" help:"Field name"`
Assignments []string `arg:"" optional:"" help:"Field attributes (e.g. type=string label=Title)"`
}
ChannelsFieldsAddCmd adds a channel field.
type ChannelsFieldsApplyCmd ¶ added in v0.1.14
type ChannelsFieldsApplyCmd struct {
Channel string `required:"" help:"Channel slug"`
File string `required:"" help:"Read field JSON array from file (use - for stdin)"`
}
ChannelsFieldsApplyCmd applies channel fields.
type ChannelsFieldsCmd ¶
type ChannelsFieldsCmd struct {
List ChannelsFieldsListCmd `cmd:"" help:"List channel fields"`
Add ChannelsFieldsAddCmd `cmd:"" help:"Add a channel field"`
Update ChannelsFieldsUpdateCmd `cmd:"" help:"Update a channel field"`
Delete ChannelsFieldsDeleteCmd `cmd:"" help:"Delete a channel field"`
Apply ChannelsFieldsApplyCmd `cmd:"" help:"Apply channel fields from JSON"`
Replace ChannelsFieldsReplaceCmd `cmd:"" help:"Replace channel fields from JSON"`
Diff ChannelsFieldsDiffCmd `cmd:"" help:"Diff channel fields against JSON"`
}
ChannelsFieldsCmd manages channel fields.
type ChannelsFieldsDeleteCmd ¶ added in v0.1.14
type ChannelsFieldsDeleteCmd struct {
Channel string `required:"" help:"Channel slug"`
Field string `required:"" help:"Field ID or name"`
}
ChannelsFieldsDeleteCmd deletes a channel field.
type ChannelsFieldsDiffCmd ¶ added in v0.1.14
type ChannelsFieldsDiffCmd struct {
Channel string `required:"" help:"Channel slug"`
File string `required:"" help:"Read field JSON array from file (use - for stdin)"`
}
ChannelsFieldsDiffCmd diffs channel fields.
type ChannelsFieldsListCmd ¶ added in v0.1.14
type ChannelsFieldsListCmd struct {
Channel string `required:"" help:"Channel slug"`
}
ChannelsFieldsListCmd lists channel fields.
type ChannelsFieldsReplaceCmd ¶ added in v0.1.14
type ChannelsFieldsReplaceCmd struct {
Channel string `required:"" help:"Channel slug"`
File string `required:"" help:"Read field JSON array from file (use - for stdin)"`
}
ChannelsFieldsReplaceCmd replaces channel fields.
type ChannelsFieldsUpdateCmd ¶ added in v0.1.14
type ChannelsFieldsUpdateCmd struct {
Channel string `required:"" help:"Channel slug"`
Field string `required:"" help:"Field ID or name"`
Assignments []string `arg:"" optional:"" help:"Field attributes to update (e.g. label=Headline required:=true)"`
}
ChannelsFieldsUpdateCmd updates a channel field.
type ChannelsGetCmd ¶
type ChannelsGetCmd struct {
Channel string `required:"" help:"Channel slug"`
}
ChannelsGetCmd gets channel details.
type ChannelsInfoCmd ¶
type ChannelsInfoCmd struct {
Channel string `required:"" help:"Channel slug or site/channel"`
TypeScript bool `name:"typescript" help:"Render a TypeScript type instead of the rich summary"`
}
ChannelsInfoCmd shows rich channel info.
type ChannelsListCmd ¶
type ChannelsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
WithEntryCount bool `name:"with-entry-count" help:"Fetch entry count for each channel" default:"true"`
NoEntryCount bool `name:"no-entry-count" help:"Skip fetching entry count for each channel"`
}
ChannelsListCmd lists channels.
type ChannelsTypesCmd ¶ added in v0.4.1
type ChannelsTypesCmd struct {
Channel []string `help:"Only include these channels (slug or ID; repeatable or comma-separated)"`
Output string `help:"Write the module to this path instead of stdout (- for stdout)" short:"o"`
}
ChannelsTypesCmd generates one TypeScript module with the types of all channels.
type CollectionsCmd ¶
type CollectionsCmd struct {
List CollectionsListCmd `cmd:"" help:"List collections"`
Get CollectionsGetCmd `cmd:"" help:"Get collection details"`
Create CollectionsCreateCmd `cmd:"" help:"Create collection from JSON"`
Update CollectionsUpdateCmd `cmd:"" help:"Update collection"`
Delete CollectionsDeleteCmd `cmd:"" help:"Delete collection"`
Count CollectionsCountCmd `cmd:"" help:"Count collections"`
Copy CollectionsCopyCmd `cmd:"" help:"Copy collections between sites"`
}
CollectionsCmd manages collections.
type CollectionsCopyCmd ¶
type CollectionsCopyCmd struct {
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
AllowErrors bool `name:"allow-errors" help:"Continue on item-level validation errors"`
}
CollectionsCopyCmd copies collections between sites.
type CollectionsCountCmd ¶
type CollectionsCountCmd struct {
CountQueryFlags `embed:""`
}
CollectionsCountCmd gets count of collections.
type CollectionsCreateCmd ¶
type CollectionsCreateCmd struct {
Locale string `help:"Content locale for localized collection fields"`
File string `help:"Read collection JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=Summer, slug=summer)"`
}
CollectionsCreateCmd creates a collection.
type CollectionsDeleteCmd ¶
type CollectionsDeleteCmd struct {
Collection string `required:"" help:"Collection ID or slug"`
}
CollectionsDeleteCmd deletes a collection.
type CollectionsGetCmd ¶
type CollectionsGetCmd struct {
Collection string `required:"" help:"Collection ID or slug"`
Locale string `help:"Content locale for localized collection fields"`
}
CollectionsGetCmd gets a collection by ID or slug.
type CollectionsListCmd ¶
type CollectionsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
CollectionsListCmd lists collections.
type CollectionsUpdateCmd ¶
type CollectionsUpdateCmd struct {
Collection string `required:"" help:"Collection ID or slug"`
Locale string `help:"Content locale for localized collection fields"`
File string `help:"Read collection JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=Summer, slug=summer)"`
}
CollectionsUpdateCmd updates a collection.
type CommandContract ¶ added in v0.3.0
type CommandContract struct {
SchemaVersion int `json:"schema_version"`
CLI string `json:"cli"`
GlobalFlags []CommandContractFlag `json:"global_flags,omitempty"`
Commands []CommandContractCommand `json:"commands"`
}
type CommandContractArgument ¶ added in v0.3.0
type CommandContractCommand ¶ added in v0.3.0
type CommandContractCommand struct {
Path string `json:"path"`
Help string `json:"help,omitempty"`
Aliases []string `json:"aliases,omitempty"`
Arguments []CommandContractArgument `json:"arguments,omitempty"`
Flags []CommandContractFlag `json:"flags,omitempty"`
}
type CommandContractFlag ¶ added in v0.3.0
type CommandsCmd ¶ added in v0.3.0
type CommandsCmd struct{}
CommandsCmd exports the machine-readable CLI contract used by docs and skills.
type CompletionCmd ¶
type CompletionCmd struct {
Shell string `help:"Shell to generate completions for (bash, zsh, fish)" default:"bash"`
}
CompletionCmd generates shell completions.
type ConfigBannerCmd ¶
type ConfigBannerCmd struct{}
ConfigBannerCmd lets users pick a banner theme interactively.
type ConfigCmd ¶
type ConfigCmd struct {
List ConfigListCmd `cmd:"" help:"List all config values"`
Get ConfigGetCmd `cmd:"" help:"Get a config value"`
Set ConfigSetCmd `cmd:"" help:"Set a config value"`
Unset ConfigUnsetCmd `cmd:"" help:"Unset a config value"`
Path ConfigPathCmd `cmd:"" help:"Print config file path"`
Banner ConfigBannerCmd `cmd:"" help:"Pick a banner theme interactively"`
}
ConfigCmd manages CLI configuration.
type ConfigGetCmd ¶
type ConfigGetCmd struct {
Key string `required:"" help:"Config key to get"`
}
ConfigGetCmd gets a config value.
type ConfigSetCmd ¶
type ConfigSetCmd struct {
Key string `required:"" help:"Config key to set"`
Value string `required:"" help:"Value to set"`
}
ConfigSetCmd sets a config value.
type ConfigUnsetCmd ¶
type ConfigUnsetCmd struct {
Key string `required:"" help:"Config key to unset"`
}
ConfigUnsetCmd unsets a config value.
type CountQueryFlags ¶ added in v0.3.0
type CountQueryFlags struct {
Locale string `help:"Locale filter; localized resources use it as content locale" group:"Query"`
Filters []string `help:"Filter by key=value, repeatable" group:"Query"`
}
CountQueryFlags contains query parameters that count endpoints can honor.
type CouponsCmd ¶
type CouponsCmd struct {
List CouponsListCmd `cmd:"" help:"List coupons"`
Get CouponsGetCmd `cmd:"" help:"Get coupon details"`
Create CouponsCreateCmd `cmd:"" help:"Create coupon from JSON"`
Update CouponsUpdateCmd `cmd:"" help:"Update coupon"`
Delete CouponsDeleteCmd `cmd:"" help:"Delete coupon"`
Count CouponsCountCmd `cmd:"" help:"Count coupons"`
}
CouponsCmd manages coupons.
type CouponsCountCmd ¶
type CouponsCountCmd struct {
CountQueryFlags `embed:""`
}
CouponsCountCmd gets count of coupons.
type CouponsCreateCmd ¶
type CouponsCreateCmd struct {
File string `help:"Read coupon JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=Promo, code=SPRING)"`
}
CouponsCreateCmd creates a coupon.
type CouponsDeleteCmd ¶
type CouponsDeleteCmd struct {
Coupon string `required:"" help:"Coupon ID"`
}
CouponsDeleteCmd deletes a coupon.
type CouponsGetCmd ¶
type CouponsGetCmd struct {
Coupon string `required:"" help:"Coupon ID"`
}
CouponsGetCmd gets a coupon by ID.
type CouponsListCmd ¶
type CouponsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
CouponsListCmd lists coupons.
type CouponsUpdateCmd ¶
type CouponsUpdateCmd struct {
Coupon string `required:"" help:"Coupon ID"`
File string `help:"Read coupon JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=Promo, code=SPRING)"`
}
CouponsUpdateCmd updates a coupon.
type CustomerRolesAddCmd ¶ added in v0.3.0
type CustomerRolesCmd ¶ added in v0.3.0
type CustomerRolesCmd struct {
List CustomerRolesListCmd `cmd:"" help:"List directly assigned customer roles"`
Set CustomerRolesSetCmd `cmd:"" help:"Replace directly assigned customer roles"`
Add CustomerRolesAddCmd `cmd:"" help:"Add directly assigned customer roles"`
Remove CustomerRolesRemoveCmd `cmd:"" help:"Remove directly assigned customer roles"`
}
type CustomerRolesListCmd ¶ added in v0.3.0
type CustomerRolesListCmd struct {
Customer string `required:"" help:"Customer ID, slug, or email"`
}
type CustomerRolesRemoveCmd ¶ added in v0.3.0
type CustomerRolesSetCmd ¶ added in v0.3.0
type CustomersCmd ¶
type CustomersCmd struct {
List CustomersListCmd `cmd:"" help:"List customers"`
Get CustomersGetCmd `cmd:"" help:"Get customer by ID or email"`
Create CustomersCreateCmd `cmd:"" help:"Create a customer"`
Update CustomersUpdateCmd `cmd:"" help:"Update a customer"`
Delete CustomersDeleteCmd `cmd:"" help:"Delete a customer"`
Count CustomersCountCmd `cmd:"" help:"Count customers"`
Copy CustomersCopyCmd `cmd:"" help:"Copy customers between sites"`
Fields CustomersFieldsCmd `cmd:"" help:"Show customer field schema"`
Config CustomersConfigCmd `cmd:"" help:"Copy or diff customer customizations"`
ResetPassword CustomersResetPasswordCmd `cmd:"reset-password" help:"Send password reset instructions"`
ResendConfirmation CustomersResendConfirmationCmd `cmd:"resend-confirmation" help:"Resend confirmation instructions"`
Roles CustomerRolesCmd `cmd:"" help:"Manage customer roles"`
}
CustomersCmd manages customers.
type CustomersConfigCmd ¶
type CustomersConfigCmd struct {
Copy CustomersConfigCopyCmd `cmd:"" help:"Copy customer customizations between sites"`
Diff CustomersConfigDiffCmd `cmd:"" help:"Diff customer customizations between sites"`
Fields CustomersFieldsCmd `cmd:"" help:"Alias for customers fields" hidden:""`
}
CustomersConfigCmd manages customer customizations.
type CustomersConfigCopyCmd ¶
type CustomersConfigCopyCmd struct {
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
}
CustomersConfigCopyCmd copies customer customizations.
type CustomersConfigDiffCmd ¶
type CustomersConfigDiffCmd struct {
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
}
CustomersConfigDiffCmd diffs customer customizations.
type CustomersCopyCmd ¶
type CustomersCopyCmd struct {
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
Query string `help:"Raw query string to append to the source customer list"`
Where string `help:"Where expression for source customer selection"`
PerPage int `help:"Items per page" name:"per-page"`
Upsert string `help:"Comma-separated upsert fields" default:"email"`
PasswordLength int `help:"Generated password length for newly created customers" name:"password-length" default:"12"`
AllowErrors bool `name:"allow-errors" help:"Continue on item-level validation errors"`
}
CustomersCopyCmd copies customers between sites.
type CustomersCountCmd ¶
type CustomersCountCmd struct {
CountQueryFlags `embed:""`
}
CustomersCountCmd gets customer count.
type CustomersCreateCmd ¶
type CustomersCreateCmd struct {
File string `help:"Read customer JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. email=a@b.com, first_name=Ana)"`
}
CustomersCreateCmd creates a customer.
type CustomersDeleteCmd ¶
type CustomersDeleteCmd struct {
Customer string `required:"" help:"Customer ID or email"`
}
CustomersDeleteCmd deletes a customer.
type CustomersFieldsCmd ¶
type CustomersFieldsCmd struct{}
CustomersFieldsCmd shows the customer field schema.
type CustomersGetCmd ¶
type CustomersGetCmd struct {
Customer string `required:"" help:"Customer ID or email"`
}
CustomersGetCmd gets a customer by ID or email.
type CustomersListCmd ¶
type CustomersListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
CustomersListCmd lists customers.
type CustomersResendConfirmationCmd ¶ added in v0.1.4
type CustomersResendConfirmationCmd struct {
Customer string `required:"" help:"Customer ID or email"`
}
type CustomersResetPasswordCmd ¶ added in v0.1.4
type CustomersResetPasswordCmd struct {
Customer string `required:"" help:"Customer ID or email"`
}
type CustomersUpdateCmd ¶
type CustomersUpdateCmd struct {
Customer string `required:"" help:"Customer ID or email"`
File string `help:"Read customer JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. first_name=Ana, phone=+32...)"`
}
CustomersUpdateCmd updates a customer.
type DomainRegistrationsCmd ¶ added in v0.3.0
type DomainRegistrationsCmd struct {
List DomainRegistrationsListCmd `cmd:"" help:"List domain registrations"`
Get DomainRegistrationsGetCmd `cmd:"" help:"Get a domain registration"`
Count DomainRegistrationsCountCmd `cmd:"" help:"Count domain registrations"`
Upsert DomainRegistrationsUpsertCmd `cmd:"" help:"Upsert registrar-managed facts by domain"`
Update DomainRegistrationsUpdateCmd `cmd:"" help:"Update commercial fields by domain"`
}
type DomainRegistrationsCountCmd ¶ added in v0.3.0
type DomainRegistrationsCountCmd struct {
CountQueryFlags `embed:""`
}
type DomainRegistrationsGetCmd ¶ added in v0.3.0
type DomainRegistrationsGetCmd struct {
ID string `required:"" help:"Domain registration short ID"`
}
type DomainRegistrationsListCmd ¶ added in v0.3.0
type DomainRegistrationsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `default:"1" help:"Page number"`
PerPage int `default:"25" help:"Items per page"`
}
type DomainRegistrationsUpdateCmd ¶ added in v0.3.0
type DomainRegistrationsUpsertCmd ¶ added in v0.3.0
type DomainsCmd ¶ added in v0.1.4
type DomainsCmd struct {
List DomainsListCmd `cmd:"" help:"List domains"`
Get DomainsGetCmd `cmd:"" help:"Get domain details"`
Create DomainsCreateCmd `cmd:"" help:"Create a domain"`
Update DomainsUpdateCmd `cmd:"" help:"Update a domain"`
Delete DomainsDeleteCmd `cmd:"" help:"Delete a domain"`
MakePrimary DomainsMakePrimaryCmd `cmd:"" help:"Make a domain primary"`
}
DomainsCmd manages custom domains.
type DomainsCreateCmd ¶ added in v0.1.4
type DomainsDeleteCmd ¶ added in v0.1.4
type DomainsDeleteCmd struct {
Domain string `required:"" help:"Domain ID or hostname"`
}
type DomainsGetCmd ¶ added in v0.1.4
type DomainsGetCmd struct {
Domain string `required:"" help:"Domain ID or hostname"`
}
type DomainsListCmd ¶ added in v0.1.4
type DomainsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
type DomainsMakePrimaryCmd ¶ added in v0.1.4
type DomainsMakePrimaryCmd struct {
Domain string `required:"" help:"Domain ID or hostname"`
}
type DomainsUpdateCmd ¶ added in v0.1.4
type EnvAddCmd ¶ added in v0.3.3
type EnvCmd ¶ added in v0.3.3
type EnvCmd struct {
List EnvListCmd `cmd:"" help:"List project environments"`
Add EnvAddCmd `cmd:"" help:"Add a project environment"`
Remove EnvRemoveCmd `cmd:"" help:"Remove a project environment"`
}
type EnvListCmd ¶ added in v0.3.3
type EnvListCmd struct{}
type EnvRemoveCmd ¶ added in v0.3.3
type EnvRemoveCmd struct {
Name string `arg:"" required:"" help:"Environment name"`
}
type EventsCmd ¶ added in v0.3.0
type EventsCmd struct {
Track EventsTrackCmd `cmd:"" help:"Track a single named event"`
Ingest EventsIngestCmd `cmd:"" help:"Ingest Count.ly-compatible events and metrics"`
}
type EventsIngestCmd ¶ added in v0.3.0
type EventsIngestCmd struct {
DeviceID string `required:"" name:"device-id" help:"Analytics device identifier"`
Events string `help:"JSON array of events"`
Metrics string `help:"JSON metrics object"`
Timestamp string `help:"Unix timestamp"`
BeginSession bool `name:"begin-session" help:"Mark the beginning of a session"`
EndSession bool `name:"end-session" help:"Mark the end of a session"`
SessionDuration string `name:"session-duration" help:"Session duration in seconds"`
}
type EventsTrackCmd ¶ added in v0.3.0
type ExitError ¶
ExitError represents an error with a specific exit code.
func MapAPIError ¶
MapAPIError maps API errors to exit codes.
type FunctionsCmd ¶
type FunctionsCmd struct {
Run FunctionsRunCmd `cmd:"" help:"Execute cloud function"`
}
FunctionsCmd executes cloud functions.
type FunctionsRunCmd ¶
type FunctionsRunCmd struct {
Function string `help:"Function identifier"`
File string `help:"Read function params JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. foo=bar, amount:=2)"`
}
FunctionsRunCmd executes a cloud function.
type InitCmd ¶
type InitCmd struct {
Directory string `` /* 169-byte string literal not displayed */
Repo string `help:"GitHub repo shorthand for the starterskit" default:"zenjoy/theme-starterskit"`
Branch string `help:"Branch to bootstrap from" default:"main"`
Dir string `help:"Use a local starterskit directory instead of cloning"`
OutputDir string `help:"Parent directory for the new project"`
}
type InternalCompleteCmd ¶ added in v0.1.14
type InternalCompleteCmd struct {
Shell string `help:"Shell requesting completions" default:"bash"`
Current string `help:"Current token being completed"`
FlagNames bool `help:"Complete flag names" hidden:""`
CommandNames bool `help:"Complete command names" hidden:""`
Words []string `arg:"" optional:"" passthrough:""`
}
type JobsCmd ¶
type JobsCmd struct {
Run JobsRunCmd `cmd:"" help:"Schedule cloud job"`
List JobsListCmd `cmd:"" help:"List jobs registered on the server"`
}
JobsCmd executes cloud jobs.
type JobsListCmd ¶ added in v0.2.6
type JobsListCmd struct {
App string `help:"Only jobs from this app (key or name)"`
}
JobsListCmd lists the cloud jobs the server knows about, across all apps.
type JobsRunCmd ¶
type JobsRunCmd struct {
Job string `help:"Job identifier"`
File string `help:"Read job params JSON from file (use - for stdin)"`
Wait bool `help:"After scheduling, tail the job's cloud-code logs until interrupted"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. foo=bar, retry:=true)"`
}
JobsRunCmd schedules a cloud job.
type MailsCmd ¶
type MailsCmd struct {
Pull NotificationsPullCmd `cmd:"" help:"Download notification templates"`
Push NotificationsPushCmd `cmd:"" help:"Upload notification templates"`
}
MailsCmd exposes legacy mail workflow aliases.
type MenusCmd ¶
type MenusCmd struct {
List MenusListCmd `cmd:"" help:"List menus"`
Get MenusGetCmd `cmd:"" help:"Get menu details"`
Create MenusCreateCmd `cmd:"" help:"Create menu from JSON"`
Update MenusUpdateCmd `cmd:"" help:"Update menu"`
Delete MenusDeleteCmd `cmd:"" help:"Delete menu"`
Count MenusCountCmd `cmd:"" help:"Count menus"`
Copy MenusCopyCmd `cmd:"" help:"Copy menus between sites"`
}
MenusCmd manages navigation menus.
type MenusCopyCmd ¶
type MenusCopyCmd struct {
Slug string `help:"Menu slug to copy" default:"*" name:"only"`
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
}
MenusCopyCmd copies menus between sites.
type MenusCountCmd ¶
type MenusCountCmd struct {
CountQueryFlags `embed:""`
}
MenusCountCmd gets menu count.
type MenusCreateCmd ¶
type MenusCreateCmd struct {
Locale string `help:"Content locale for localized menu fields"`
File string `help:"Read menu JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=Main, handle=main)"`
}
MenusCreateCmd creates a menu.
type MenusDeleteCmd ¶
type MenusDeleteCmd struct {
Menu string `required:"" help:"Menu ID or handle"`
}
MenusDeleteCmd deletes a menu.
type MenusGetCmd ¶
type MenusGetCmd struct {
Menu string `required:"" help:"Menu slug or handle"`
Locale string `help:"Content locale for localized menu fields"`
}
MenusGetCmd gets menu details.
type MenusListCmd ¶
type MenusListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
MenusListCmd lists menus.
type MenusUpdateCmd ¶
type MenusUpdateCmd struct {
Menu string `required:"" help:"Menu slug or handle"`
Locale string `help:"Content locale for localized menu fields"`
File string `help:"Read menu JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=Main, handle=main)"`
}
MenusUpdateCmd updates a menu.
type NotificationsCmd ¶
type NotificationsCmd struct {
List NotificationsListCmd `cmd:"" help:"List notifications"`
Get NotificationsGetCmd `cmd:"" help:"Get notification details"`
Pull NotificationsPullCmd `cmd:"" help:"Download notification templates"`
Push NotificationsPushCmd `cmd:"" help:"Upload notification templates"`
Create NotificationsCreateCmd `cmd:"" help:"Create notification from JSON"`
Update NotificationsUpdateCmd `cmd:"" help:"Update notification"`
Delete NotificationsDeleteCmd `cmd:"" help:"Delete notification"`
Count NotificationsCountCmd `cmd:"" help:"Count notifications"`
Copy NotificationsCopyCmd `cmd:"" help:"Copy notifications between sites"`
}
NotificationsCmd manages notifications.
type NotificationsCopyCmd ¶
type NotificationsCopyCmd struct {
Slug string `help:"Notification slug to copy" default:"*" name:"only"`
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
}
NotificationsCopyCmd copies notifications between sites.
type NotificationsCountCmd ¶
type NotificationsCountCmd struct {
CountQueryFlags `embed:""`
}
NotificationsCountCmd gets count of notifications.
type NotificationsCreateCmd ¶
type NotificationsCreateCmd struct {
Locale string `help:"Content locale for localized notification fields"`
File string `help:"Read notification JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. slug=order_created, subject=Hello)"`
}
NotificationsCreateCmd creates a notification.
type NotificationsDeleteCmd ¶
type NotificationsDeleteCmd struct {
Notification string `required:"" help:"Notification slug or identifier"`
}
NotificationsDeleteCmd deletes a notification.
type NotificationsGetCmd ¶
type NotificationsGetCmd struct {
Notification string `required:"" help:"Notification slug or identifier"`
Locale string `help:"Content locale for localized notification fields"`
}
NotificationsGetCmd gets a notification by slug.
type NotificationsListCmd ¶
type NotificationsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
NotificationsListCmd lists notifications.
type NotificationsPullCmd ¶
type NotificationsPullCmd struct {
Only []string `help:"Only these notification slugs" name:"only"`
}
NotificationsPullCmd downloads notifications into content/notifications.
type NotificationsPushCmd ¶
type NotificationsPushCmd struct {
Only []string `help:"Notification slugs to push" short:"o"`
}
NotificationsPushCmd uploads local notifications from disk.
type NotificationsUpdateCmd ¶
type NotificationsUpdateCmd struct {
Notification string `required:"" help:"Notification slug or identifier"`
Locale string `help:"Content locale for localized notification fields"`
File string `help:"Read notification JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. subject=Hello, html_enabled:=true)"`
}
NotificationsUpdateCmd updates a notification.
type OrdersArchiveCmd ¶ added in v0.1.4
type OrdersArchiveCmd struct {
Order string `required:"" help:"Order ID or number"`
}
type OrdersCancelCmd ¶ added in v0.1.4
type OrdersCmd ¶
type OrdersCmd struct {
List OrdersListCmd `cmd:"" help:"List orders"`
Get OrdersGetCmd `cmd:"" help:"Get order by ID or number"`
Update OrdersUpdateCmd `cmd:"" help:"Update order (status changes)"`
Count OrdersCountCmd `cmd:"" help:"Count orders"`
Pay OrdersPayCmd `cmd:"" help:"Record manual payment for an order"`
Finish OrdersFinishCmd `cmd:"" help:"Finish a paid order"`
Cancel OrdersCancelCmd `cmd:"" help:"Cancel a completed order"`
Reopen OrdersReopenCmd `cmd:"" help:"Reopen a done or canceled order"`
Archive OrdersArchiveCmd `cmd:"" help:"Archive a done or canceled order"`
}
OrdersCmd manages orders.
type OrdersCountCmd ¶
type OrdersCountCmd struct {
CountQueryFlags `embed:""`
Status string `help:"Filter by status"`
}
OrdersCountCmd counts orders.
type OrdersFinishCmd ¶ added in v0.1.4
type OrdersGetCmd ¶
type OrdersGetCmd struct {
Order string `required:"" help:"Order ID or number"`
}
OrdersGetCmd gets an order by ID or number.
type OrdersListCmd ¶
type OrdersListCmd struct {
QueryFlags `embed:""`
Status string `help:"Filter by status"`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
OrdersListCmd lists orders.
type OrdersPayCmd ¶ added in v0.1.4
type OrdersPayCmd struct {
Order string `required:"" help:"Order ID or number"`
}
type OrdersReopenCmd ¶ added in v0.1.4
type OrdersReopenCmd struct {
Order string `required:"" help:"Order ID or number"`
}
type OrdersUpdateCmd ¶
type OrdersUpdateCmd struct {
Order string `required:"" help:"Order ID or number"`
Status string `help:"Set order status"`
File string `help:"Read order JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. status=paid, note=Done)"`
}
OrdersUpdateCmd updates an order.
type PageVersionsCmd ¶ added in v0.3.0
type PageVersionsCmd struct {
List PageVersionsListCmd `cmd:"" help:"List page versions"`
Get PageVersionsGetCmd `cmd:"" help:"Get a page version"`
Restore PageVersionsRestoreCmd `cmd:"" help:"Restore a page version"`
}
type PageVersionsGetCmd ¶ added in v0.3.0
type PageVersionsListCmd ¶ added in v0.3.0
type PageVersionsListCmd struct {
Page string `required:"" help:"Page ID or path"`
}
type PageVersionsRestoreCmd ¶ added in v0.3.0
type PagesBatchCmd ¶ added in v0.3.1
type PagesBatchCmd struct {
Page string `required:"" help:"Page fullpath or id"`
File string `required:"" help:"JSON operations object or array"`
Atomic bool `default:"true" negatable:"" help:"Fail the whole batch if any operation fails"`
Locale string `help:"Content locale for localized fields"`
Diff bool `help:"Show a unified diff of each changed subtree"`
DryRun bool `help:"Resolve paths and print the operations without writing"`
Draft bool `help:"Write to the page draft instead of the live page"`
}
PagesBatchCmd applies multiple page operations from a file.
func (*PagesBatchCmd) Help ¶ added in v0.3.2
func (c *PagesBatchCmd) Help() string
type PagesCmd ¶
type PagesCmd struct {
List PagesListCmd `cmd:"" help:"List pages"`
Get PagesGetCmd `cmd:"" help:"Get page details"`
Create PagesCreateCmd `cmd:"" help:"Create page from JSON"`
Update PagesUpdateCmd `cmd:"" help:"Update page"`
Delete PagesDeleteCmd `cmd:"" help:"Delete page"`
Set PagesSetCmd `cmd:"" help:"Set one page field or editable by path"`
Insert PagesInsertCmd `cmd:"" help:"Insert a repeatable into a canvas"`
DeleteBlock PagesDeleteBlockCmd `cmd:"" name:"delete-block" help:"Delete a repeatable block"`
Move PagesMoveCmd `cmd:"" help:"Move a repeatable within its canvas"`
Batch PagesBatchCmd `cmd:"" help:"Apply multiple page operations from a file"`
Draft PagesDraftCmd `cmd:"" help:"Work on page drafts (edit and preview without publishing)"`
Items PagesItemsCmd `cmd:"" help:"Get a resolved items subtree"`
Schema PagesSchemaCmd `cmd:"" help:"Show the page template schema"`
Count PagesCountCmd `cmd:"" help:"Count pages"`
Copy PagesCopyCmd `cmd:"" help:"Copy pages between sites"`
Versions PageVersionsCmd `cmd:"" help:"Manage page versions"`
}
PagesCmd manages pages.
type PagesCopyCmd ¶
type PagesCopyCmd struct {
Fullpath string `help:"Page fullpath or prefix* to copy" default:"*" name:"only"`
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
AllowErrors bool `help:"Continue on page-level errors" name:"allow-errors"`
}
PagesCopyCmd copies pages between sites.
type PagesCountCmd ¶
type PagesCountCmd struct {
CountQueryFlags `embed:""`
}
PagesCountCmd gets page count.
type PagesCreateCmd ¶
type PagesCreateCmd struct {
Locale string `help:"Content locale for localized page fields"`
File string `help:"Read page JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. slug=about, title=About)"`
}
PagesCreateCmd creates a page.
func (*PagesCreateCmd) Help ¶ added in v0.3.1
func (c *PagesCreateCmd) Help() string
type PagesDeleteBlockCmd ¶ added in v0.3.1
type PagesDeleteBlockCmd struct {
Page string `required:"" help:"Page fullpath or id"`
Path string `required:"" help:"Repeatable path to delete"`
Diff bool `help:"Show a unified diff of the canvas repeatables"`
DryRun bool `help:"Resolve paths and print the operations without writing"`
Draft bool `help:"Write to the page draft instead of the live page"`
}
PagesDeleteBlockCmd deletes a repeatable block.
type PagesDeleteCmd ¶
type PagesDeleteCmd struct {
Page string `required:"" help:"Page ID or slug"`
}
PagesDeleteCmd deletes a page.
type PagesDraftBatchCmd ¶ added in v0.3.1
type PagesDraftBatchCmd struct {
Page string `required:"" help:"Page fullpath or id"`
File string `required:"" help:"JSON operations object or array"`
Locale string `help:"Content locale for localized fields"`
Diff bool `help:"Show a unified diff of each changed subtree"`
DryRun bool `help:"Resolve paths and print the operations without writing"`
}
PagesDraftBatchCmd is an alias for pages batch --draft.
type PagesDraftCmd ¶ added in v0.3.1
type PagesDraftCmd struct {
Get PagesDraftGetCmd `cmd:"" help:"Get the current page draft"`
Save PagesDraftSaveCmd `cmd:"" help:"Save a whole page draft from a file"`
Batch PagesDraftBatchCmd `cmd:"" help:"Apply operations to the page draft"`
Publish PagesDraftPublishCmd `cmd:"" help:"Publish a page draft to the live page"`
Discard PagesDraftDiscardCmd `cmd:"" help:"Discard a page draft"`
PreviewURL PagesDraftPreviewURLCmd `cmd:"" name:"preview-url" help:"Print a preview URL for the page draft"`
}
PagesDraftCmd groups page draft subcommands.
type PagesDraftDiscardCmd ¶ added in v0.3.1
type PagesDraftDiscardCmd struct {
Page string `required:"" help:"Page fullpath or id"`
}
PagesDraftDiscardCmd deletes the current page draft.
type PagesDraftGetCmd ¶ added in v0.3.1
type PagesDraftGetCmd struct {
Page string `required:"" help:"Page fullpath or id"`
Locale string `help:"Content locale for localized fields"`
Shape bool `help:"Emit canvas/repeatable skeleton instead of content"`
Raw bool `help:"Emit the raw draft envelope (content.page_items) instead of the page document"`
}
PagesDraftGetCmd fetches GET /pages/{id}/draft.
type PagesDraftPreviewURLCmd ¶ added in v0.3.1
type PagesDraftPreviewURLCmd struct {
Page string `required:"" help:"Page fullpath or id"`
Open bool `help:"Open the preview URL in the browser"`
}
PagesDraftPreviewURLCmd prints an absolute draft preview URL.
type PagesDraftPublishCmd ¶ added in v0.3.1
type PagesDraftPublishCmd struct {
Page string `required:"" help:"Page fullpath or id"`
Confirm bool `help:"Replace live content when the live page changed after this draft was based on it"`
}
PagesDraftPublishCmd publishes a draft to the live page.
type PagesDraftSaveCmd ¶ added in v0.3.1
type PagesDraftSaveCmd struct {
Page string `required:"" help:"Page fullpath or id"`
File string `required:"" help:"Draft JSON file (use - for stdin)"`
Locale string `help:"Content locale for localized fields"`
}
PagesDraftSaveCmd posts a page-like body to /pages/{id}/draft.
type PagesGetCmd ¶
type PagesGetCmd struct {
QueryFlags `embed:""`
DownloadAssets string `help:"Download page file editables into DIR and rewrite JSON to attachment_path refs"`
Shape bool `help:"Emit canvas/repeatable skeleton instead of content"`
Outline bool `help:"Emit one compact line per editable (paths usable with pages set --path)"`
Compact bool `help:"JSON only: drop editable timestamps/slug/type, redundant translations, and file noise"`
Draft bool `help:"Read the page draft instead of the live page (works with --shape, --outline, --compact)"`
Page string `required:"" help:"Page fullpath"`
}
PagesGetCmd gets page details.
type PagesInsertCmd ¶ added in v0.3.1
type PagesInsertCmd struct {
Page string `required:"" help:"Page fullpath or id"`
Path string `required:"" help:"Canvas path (Blokken, /items/Blokken, or /items/Blokken/repeatables)"`
Slug string `help:"Repeatable slug to insert"`
After string `help:"Place after this sibling id or 0-based index" xor:"insert-at"`
Position *int `help:"0-based insert index" xor:"insert-at"`
File string `help:"JSON items map, or {slug, items} object"`
Locale string `help:"Content locale for localized fields"`
Diff bool `help:"Show a unified diff of the canvas repeatables"`
DryRun bool `help:"Resolve paths and print the operations without writing"`
Draft bool `help:"Write to the page draft instead of the live page"`
}
PagesInsertCmd inserts a repeatable into a canvas.
type PagesItemsCmd ¶ added in v0.3.1
type PagesItemsCmd struct {
Page string `required:"" help:"Page fullpath or id"`
Path string `required:"" help:"Human or raw path under /items"`
Locale string `help:"Content locale; overlays translations for display"`
}
PagesItemsCmd gets a resolved items subtree.
type PagesListCmd ¶
type PagesListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
PagesListCmd lists pages.
type PagesMoveCmd ¶ added in v0.3.1
type PagesMoveCmd struct {
Page string `required:"" help:"Page fullpath or id"`
Path string `required:"" help:"Repeatable path to move"`
After string `help:"Place after this sibling id or 0-based index" xor:"move-at"`
Position *int `help:"0-based target index" xor:"move-at"`
Diff bool `help:"Show a unified diff of the canvas repeatables"`
DryRun bool `help:"Resolve paths and print the operations without writing"`
Draft bool `help:"Write to the page draft instead of the live page"`
}
PagesMoveCmd moves a repeatable within its canvas.
type PagesSchemaCmd ¶ added in v0.3.1
type PagesSchemaCmd struct {
Page string `required:"" help:"Page fullpath or id"`
}
PagesSchemaCmd shows the page template schema.
type PagesSetCmd ¶ added in v0.3.1
type PagesSetCmd struct {
Page string `required:"" help:"Page fullpath or id"`
Path string `required:"" help:"Human or raw path to the field or editable"`
Value string `arg:"" optional:"" xor:"set-source" help:"Literal value to set"`
File string `help:"JSON value from file (use - for stdin)" xor:"set-source"`
FromFile string `name:"from-file" help:"Local file to upload as a file editable" xor:"set-source"`
Locale string `help:"Content locale for localized fields"`
Diff bool `help:"Show a unified diff of the changed subtree"`
DryRun bool `help:"Resolve paths and print the operations without writing"`
Draft bool `help:"Write to the page draft instead of the live page"`
}
PagesSetCmd sets one page field or editable by path.
type PagesUpdateCmd ¶
type PagesUpdateCmd struct {
QueryFlags `embed:""`
Page string `required:"" help:"Page fullpath"`
File string `help:"Read page JSON from file (use - for stdin)"`
Replace bool `help:"Replace canvases entirely (destructive rebuild)"`
AllowEmptyCanvas bool `help:"Allow emptying a canvas"`
AllowEmptyFile bool `help:"Allow file editables with no attachment or URL to clear assets"`
DryRun bool `name:"dry-run" help:"Fetch, merge, and print the PATCH body without sending it"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. title=About, published:=true)"`
}
PagesUpdateCmd updates a page.
func (*PagesUpdateCmd) Help ¶ added in v0.3.1
func (c *PagesUpdateCmd) Help() string
type ProductAttachmentsCmd ¶ added in v0.3.0
type ProductAttachmentsCmd struct {
List ProductAttachmentsListCmd `cmd:"" help:"List product attachments"`
Get ProductAttachmentsGetCmd `cmd:"" help:"Get a product attachment"`
Create ProductAttachmentsCreateCmd `cmd:"" help:"Create a product attachment"`
Update ProductAttachmentsUpdateCmd `cmd:"" help:"Update a product attachment"`
Delete ProductAttachmentsDeleteCmd `cmd:"" help:"Delete a product attachment (requires --force)"`
Download ProductAttachmentsDownloadCmd `cmd:"" help:"Download a product attachment"`
}
type ProductAttachmentsCreateCmd ¶ added in v0.3.0
type ProductAttachmentsDeleteCmd ¶ added in v0.3.0
type ProductAttachmentsDownloadCmd ¶ added in v0.3.0
type ProductAttachmentsGetCmd ¶ added in v0.3.0
type ProductAttachmentsListCmd ¶ added in v0.3.0
type ProductAttachmentsListCmd struct {
QueryFlags `embed:""`
Product string `required:"" help:"Product ID or slug"`
}
type ProductAttachmentsUpdateCmd ¶ added in v0.3.0
type ProductsCmd ¶
type ProductsCmd struct {
List ProductsListCmd `cmd:"" help:"List products"`
Get ProductsGetCmd `cmd:"" help:"Get product by ID or slug"`
Create ProductsCreateCmd `cmd:"" help:"Create a product"`
Update ProductsUpdateCmd `cmd:"" help:"Update a product"`
Delete ProductsDeleteCmd `cmd:"" help:"Delete a product"`
Count ProductsCountCmd `cmd:"" help:"Count products"`
Fields ProductsFieldsCmd `cmd:"" help:"Show product field schema"`
Config ProductsConfigCmd `cmd:"" help:"Copy or diff product customizations"`
Copy ProductsCopyCmd `cmd:"" help:"Copy products between sites"`
Attachments ProductAttachmentsCmd `cmd:"" help:"Manage product attachments"`
}
ProductsCmd manages products.
type ProductsConfigCmd ¶
type ProductsConfigCmd struct {
Copy ProductsConfigCopyCmd `cmd:"" help:"Copy product customizations between sites"`
Diff ProductsConfigDiffCmd `cmd:"" help:"Diff product customizations between sites"`
Fields ProductsFieldsCmd `cmd:"" help:"Alias for products fields" hidden:""`
}
ProductsConfigCmd manages product customizations.
type ProductsConfigCopyCmd ¶
type ProductsConfigCopyCmd struct {
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
}
ProductsConfigCopyCmd copies product customizations.
type ProductsConfigDiffCmd ¶
type ProductsConfigDiffCmd struct {
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
}
ProductsConfigDiffCmd diffs product customizations.
type ProductsCopyCmd ¶
type ProductsCopyCmd struct {
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
AllowErrors bool `name:"allow-errors" help:"Continue on item-level validation errors"`
}
ProductsCopyCmd copies products between sites.
type ProductsCountCmd ¶
type ProductsCountCmd struct {
CountQueryFlags `embed:""`
}
ProductsCountCmd gets count of products.
type ProductsCreateCmd ¶
type ProductsCreateCmd struct {
Locale string `help:"Content locale for localized product fields"`
File string `help:"Read product JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=Wine, price:=19.9)"`
}
ProductsCreateCmd creates a product.
type ProductsDeleteCmd ¶
type ProductsDeleteCmd struct {
Product string `required:"" help:"Product ID or slug"`
}
ProductsDeleteCmd deletes a product.
type ProductsFieldsCmd ¶
type ProductsFieldsCmd struct{}
ProductsFieldsCmd shows the product field schema.
type ProductsGetCmd ¶
type ProductsGetCmd struct {
Product string `required:"" help:"Product ID or slug"`
Locale string `help:"Content locale for localized product fields"`
}
ProductsGetCmd gets a product by ID or slug.
type ProductsListCmd ¶
type ProductsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
ProductsListCmd lists products.
type ProductsUpdateCmd ¶
type ProductsUpdateCmd struct {
Product string `required:"" help:"Product ID or slug"`
Locale string `help:"Content locale for localized product fields"`
File string `help:"Read product JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=Wine, price:=19.9)"`
}
ProductsUpdateCmd updates a product.
type QueryFlags ¶ added in v0.1.5
type QueryFlags struct {
Fields string `help:"Comma-separated fields to return" group:"Query"`
Locale string `help:"Locale filter; localized resources use it as content locale" group:"Query"`
Include string `help:"Include related resources" group:"Query"`
Sort string `help:"Sort by field, e.g. field or field:desc" group:"Query"`
Filters []string `help:"Filter by key=value, repeatable" group:"Query"`
}
QueryFlags contains flags for filtering/sorting API list responses. Embedded by commands that support query parameters.
type RealtimeCmd ¶ added in v0.3.3
type RealtimeCmd struct {
Grant RealtimeGrantCmd `cmd:"" help:"Mint a single-use realtime grant"`
}
RealtimeCmd groups realtime (websocket) helpers.
type RealtimeGrantCmd ¶ added in v0.3.3
type RealtimeGrantCmd struct{}
RealtimeGrantCmd mints a single-use realtime grant.
type RedirectsCmd ¶
type RedirectsCmd struct {
List RedirectsListCmd `cmd:"" help:"List redirects"`
Get RedirectsGetCmd `cmd:"" help:"Get redirect details"`
Create RedirectsCreateCmd `cmd:"" help:"Create redirect from JSON"`
Update RedirectsUpdateCmd `cmd:"" help:"Update redirect"`
Delete RedirectsDeleteCmd `cmd:"" help:"Delete redirect"`
Copy RedirectsCopyCmd `cmd:"" help:"Copy redirects between sites"`
}
RedirectsCmd manages redirects.
type RedirectsCopyCmd ¶
type RedirectsCopyCmd struct {
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
}
RedirectsCopyCmd copies redirects between sites.
type RedirectsCreateCmd ¶
type RedirectsCreateCmd struct {
File string `help:"Read redirect JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. source=/old, target=/new)"`
}
RedirectsCreateCmd creates a redirect.
type RedirectsDeleteCmd ¶
type RedirectsDeleteCmd struct {
Redirect string `required:"" help:"Redirect ID"`
}
RedirectsDeleteCmd deletes a redirect.
type RedirectsGetCmd ¶
type RedirectsGetCmd struct {
Redirect string `required:"" help:"Redirect ID"`
}
RedirectsGetCmd gets a redirect by ID.
type RedirectsListCmd ¶
type RedirectsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
RedirectsListCmd lists redirects.
type RedirectsUpdateCmd ¶
type RedirectsUpdateCmd struct {
Redirect string `required:"" help:"Redirect ID"`
File string `help:"Read redirect JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. source=/old, target=/new)"`
}
RedirectsUpdateCmd updates a redirect.
type ReleaseCmd ¶ added in v0.3.3
type ReleaseCmd struct {
Only []string `help:"Release stages: schema,code,theme" name:"only"`
DryRun bool `help:"Plan each selected stage without deploying" name:"dry-run"`
AllowDirty bool `help:"Allow uncommitted changes; mark the release dirty" name:"allow-dirty"`
Yes bool `help:"Confirm protected environment deployment"`
}
ReleaseCmd deploys the checked-out project and records successful releases.
type ReleasesCmd ¶ added in v0.3.3
type ReleasesCmd struct{}
ReleasesCmd lists successful releases for the selected site.
type RolesCmd ¶
type RolesCmd struct {
List RolesListCmd `cmd:"" help:"List roles"`
Get RolesGetCmd `cmd:"" help:"Get role details"`
Create RolesCreateCmd `cmd:"" help:"Create role from JSON"`
Update RolesUpdateCmd `` /* 133-byte string literal not displayed */
Delete RolesDeleteCmd `cmd:"" help:"Delete role"`
Copy RolesCopyCmd `cmd:"" help:"Copy roles between sites"`
Customers RolesCustomersCmd `cmd:"" help:"Add, remove, or replace customers on a role"`
}
RolesCmd manages roles.
type RolesCopyCmd ¶
type RolesCopyCmd struct {
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
}
RolesCopyCmd copies customer roles between sites.
type RolesCreateCmd ¶
type RolesCreateCmd struct {
File string `help:"Read role JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=VIP)"`
}
RolesCreateCmd creates a role.
type RolesCustomersAddCmd ¶ added in v0.3.1
type RolesCustomersAddCmd struct {
Role string `required:"" help:"Role ID"`
Customers []string `required:"" name:"customer" help:"Customer ID to add, repeatable"`
}
RolesCustomersAddCmd adds customers to a role.
type RolesCustomersCmd ¶ added in v0.3.1
type RolesCustomersCmd struct {
Add RolesCustomersAddCmd `cmd:"" help:"Add customers to a role"`
Remove RolesCustomersRemoveCmd `cmd:"" help:"Remove customers from a role"`
Set RolesCustomersSetCmd `cmd:"" help:"Replace a role's customer list"`
}
RolesCustomersCmd edits the customers relation on a role.
type RolesCustomersRemoveCmd ¶ added in v0.3.1
type RolesCustomersRemoveCmd struct {
Role string `required:"" help:"Role ID"`
Customers []string `required:"" name:"customer" help:"Customer ID to remove, repeatable"`
}
RolesCustomersRemoveCmd removes customers from a role.
type RolesCustomersSetCmd ¶ added in v0.3.1
type RolesCustomersSetCmd struct {
Role string `required:"" help:"Role ID"`
Customers []string `required:"" name:"customer" help:"Customer ID that should remain, repeatable"`
}
RolesCustomersSetCmd replaces the customers on a role.
type RolesDeleteCmd ¶
type RolesDeleteCmd struct {
Role string `required:"" help:"Role ID"`
}
RolesDeleteCmd deletes a role.
type RolesGetCmd ¶
type RolesGetCmd struct {
Role string `required:"" help:"Role ID"`
}
RolesGetCmd gets a role by ID.
type RolesListCmd ¶
type RolesListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
RolesListCmd lists roles.
type RolesUpdateCmd ¶
type RolesUpdateCmd struct {
Role string `required:"" help:"Role ID"`
File string `help:"Read role JSON from file (use - for stdin)"`
DryRun bool `name:"dry-run" help:"Print the request body and relation diff without writing"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=VIP)"`
}
RolesUpdateCmd updates a role.
Array fields (customers, children, parents) replace the whole relation. Server-side __op envelopes (AddReference/RemoveReference/Batch, plus AddRelation/RemoveRelation aliases) are sent verbatim.
type RootFlags ¶
type RootFlags struct {
Environment string `name:"env" help:"Named project environment (overrides site and API URL)"`
SelectedEnvironmentProtected bool `kong:"-"`
// Essential (ungrouped — always visible in help)
Site string `help:"Site ID or subdomain, else nimbu.yml site" env:"NIMBU_SITE"`
JSON bool `help:"Output JSON to stdout" default:"${json}" env:"NIMBU_JSON"`
Plain bool `help:"Output stable TSV to stdout" default:"${plain}" env:"NIMBU_PLAIN"`
Verbose bool `help:"Enable verbose logging"`
Debug bool `help:"Enable debug logging (HTTP traces)"`
// Output (suppressed in default help)
Color string `help:"Color output: auto|always|never" default:"${color}" env:"NIMBU_COLOR" group:"Output"`
NoProgress bool `help:"Disable live progress UI" env:"NIMBU_NO_PROGRESS" group:"Output"`
// Agent/CI (suppressed in default help)
Force bool `help:"Skip confirmations for destructive operations" group:"Agent/CI"`
NoInput bool `help:"Never prompt; fail instead (for CI)" env:"NIMBU_NO_INPUT" group:"Agent/CI"`
Readonly bool `help:"Disable all write operations" env:"NIMBU_READONLY" group:"Agent/CI"`
EnableCommands string `help:"Comma-separated allowlist of commands" env:"NIMBU_ENABLE_COMMANDS" group:"Agent/CI"`
// Connection (suppressed in default help)
APIURL string `help:"API base URL" default:"https://api.nimbu.io" env:"NIMBU_API_URL" group:"Connection"`
Timeout time.Duration `help:"Request timeout" default:"30s" env:"NIMBU_TIMEOUT" group:"Connection"`
}
RootFlags contains global flags available to all commands.
type SchemaApplyCmd ¶ added in v0.3.3
type SchemaCmd ¶ added in v0.3.3
type SchemaCmd struct {
Pull SchemaPullCmd `cmd:"" help:"Pull live schemas into local files"`
Plan SchemaPlanCmd `cmd:"" help:"Preview declarative schema changes"`
Apply SchemaApplyCmd `cmd:"" help:"Apply declarative schema changes"`
}
type SchemaPlanCmd ¶ added in v0.3.3
type SchemaPlanCmd struct {
Plans []schemaPlan `kong:"-"`
Prune bool `help:"Remove fields and options absent from supplied arrays"`
}
type SchemaPullCmd ¶ added in v0.3.3
type SchemaPullCmd struct {
Only []string `name:"only" help:"Targets to pull, e.g. channels/events,products"`
}
SchemaPullCmd exports the site's declarative schemas.
type SendersCmd ¶ added in v0.1.4
type SendersCmd struct {
List SendersListCmd `cmd:"" help:"List sender domains"`
Get SendersGetCmd `cmd:"" help:"Get sender domain details"`
Create SendersCreateCmd `cmd:"" help:"Create a sender domain"`
VerifyOwnership SendersVerifyOwnershipCmd `cmd:"verify-ownership" help:"Verify sender domain ownership"`
Verify SendersVerifyCmd `cmd:"" help:"Verify sender domain DNS"`
}
SendersCmd manages email sender domains.
type SendersCreateCmd ¶ added in v0.1.4
type SendersCreateCmd struct {
Domain string `required:"" help:"Sender domain"`
}
type SendersGetCmd ¶ added in v0.1.4
type SendersGetCmd struct {
Sender string `required:"" help:"Sender ID or domain"`
}
type SendersListCmd ¶ added in v0.1.4
type SendersListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
type SendersVerifyCmd ¶ added in v0.1.4
type SendersVerifyCmd struct {
Sender string `required:"" help:"Sender ID or domain"`
}
type SendersVerifyOwnershipCmd ¶ added in v0.1.4
type SendersVerifyOwnershipCmd struct {
Sender string `required:"" help:"Sender ID or domain"`
}
type ServerCmd ¶
type ServerCmd struct {
Arg []string `help:"Child dev server arguments (repeatable)" name:"arg"`
CMD string `help:"Override child dev server executable" name:"cmd"`
CWD string `help:"Override child working directory"`
Draft []string `` /* 221-byte string literal not displayed */
EventsJSON bool `help:"Emit structured runtime events as JSON lines"`
MaxBodyMB int `help:"Max request body size in MB for simulator proxy" default:"0"`
NoWatch bool `help:"Disable filesystem watcher invalidation"`
ProxyHost string `help:"Proxy host" default:""`
ProxyPort int `help:"Proxy port" default:"0"`
QuietRequests bool `help:"Disable per-request proxy log lines"`
ReadyTimeout time.Duration `help:"Child readiness timeout" default:"0s"`
ReadyURL string `help:"Override child readiness URL"`
TemplateRoot string `help:"Override template root directory"`
WatchScanInterval time.Duration `help:"Fallback template scan interval" default:"0s"`
}
ServerCmd starts the local simulator proxy and child dev server.
type SettingsCmd ¶ added in v0.3.0
type SettingsCmd struct {
Get SettingsGetCmd `cmd:"" help:"Get a settings section"`
Update SettingsUpdateCmd `cmd:"" help:"Update a settings section"`
Consent SettingsConsentCmd `cmd:"" help:"Manage consent resources"`
}
type SettingsConsentCmd ¶ added in v0.3.0
type SettingsConsentCmd struct {
Config SettingsConsentConfigCmd `cmd:"" help:"Manage the complete consent configuration"`
List SettingsConsentListCmd `cmd:"" help:"List consent resources"`
Get SettingsConsentGetCmd `cmd:"" help:"Get a consent resource"`
Create SettingsConsentCreateCmd `cmd:"" help:"Create a consent resource"`
Update SettingsConsentUpdateCmd `cmd:"" help:"Update a consent resource"`
Delete SettingsConsentDeleteCmd `cmd:"" help:"Delete a consent resource (requires --force)"`
}
type SettingsConsentConfigCmd ¶ added in v0.3.0
type SettingsConsentConfigCmd struct {
Get SettingsConsentConfigGetCmd `cmd:"" help:"Get the complete consent configuration"`
Update SettingsConsentConfigUpdateCmd `cmd:"" help:"Update consent configuration fields"`
Replace SettingsConsentConfigReplaceCmd `cmd:"" help:"Replace the complete consent configuration (requires --force)"`
Copy SettingsConsentConfigCopyCmd `cmd:"" help:"Copy the complete consent configuration between sites"`
}
SettingsConsentConfigCmd manages the whole consent configuration.
type SettingsConsentConfigCopyCmd ¶ added in v0.3.0
type SettingsConsentConfigCopyCmd struct {
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
DryRun bool `name:"dry-run" help:"Resolve and report changes without writing the target"`
}
SettingsConsentConfigCopyCmd copies the complete consent configuration.
type SettingsConsentConfigGetCmd ¶ added in v0.3.0
type SettingsConsentConfigGetCmd struct{}
type SettingsConsentConfigReplaceCmd ¶ added in v0.3.0
type SettingsConsentConfigReplaceCmd struct {
File string `help:"Read complete JSON configuration from file (use - for stdin)" required:""`
}
type SettingsConsentConfigUpdateCmd ¶ added in v0.3.0
type SettingsConsentCreateCmd ¶ added in v0.3.0
type SettingsConsentDeleteCmd ¶ added in v0.3.0
type SettingsConsentGetCmd ¶ added in v0.3.0
type SettingsConsentListCmd ¶ added in v0.3.0
type SettingsConsentListCmd struct {
Kind string `required:"" enum:"purposes,cookies,applications" help:"Consent resource kind"`
}
type SettingsConsentUpdateCmd ¶ added in v0.3.0
type SettingsConsentUpdateCmd struct {
Kind string `required:"" enum:"purposes,cookies,applications" help:"Consent resource kind"`
Key string `required:"" help:"Purpose/application key or cookie ID"`
File string `help:"Read JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline consent resource assignments"`
}
type SettingsGetCmd ¶ added in v0.3.0
type SettingsGetCmd struct {
Section string `required:"" enum:"checkout,notifications,taxes,shipping,shop,email" help:"Settings section"`
}
type SettingsUpdateCmd ¶ added in v0.3.0
type ShippingRatesCmd ¶ added in v0.3.0
type ShippingRatesCmd struct {
List ShippingRatesListCmd `cmd:"" help:"List shipping rates"`
Get ShippingRatesGetCmd `cmd:"" help:"Get shipping rate details"`
Create ShippingRatesCreateCmd `cmd:"" help:"Create a shipping rate"`
Update ShippingRatesUpdateCmd `cmd:"" help:"Update a shipping rate"`
Delete ShippingRatesDeleteCmd `cmd:"" help:"Delete a shipping rate"`
}
ShippingRatesCmd manages shipping rates.
type ShippingRatesCreateCmd ¶ added in v0.3.0
type ShippingRatesCreateCmd struct {
Locale string `help:"Content locale for localized shipping rate fields"`
File string `help:"Read shipping rate JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=Express, price:=12.5)"`
}
ShippingRatesCreateCmd creates a shipping rate.
type ShippingRatesDeleteCmd ¶ added in v0.3.0
type ShippingRatesDeleteCmd struct {
Rate string `required:"" help:"Shipping rate ID"`
}
ShippingRatesDeleteCmd deletes a shipping rate.
type ShippingRatesGetCmd ¶ added in v0.3.0
type ShippingRatesGetCmd struct {
Rate string `required:"" help:"Shipping rate ID"`
Locale string `help:"Content locale for localized shipping rate fields"`
}
ShippingRatesGetCmd gets a shipping rate by ID.
type ShippingRatesListCmd ¶ added in v0.3.0
type ShippingRatesListCmd struct {
QueryFlags `embed:""`
}
ShippingRatesListCmd lists shipping rates without pagination.
type ShippingRatesUpdateCmd ¶ added in v0.3.0
type ShippingRatesUpdateCmd struct {
Rate string `required:"" help:"Shipping rate ID"`
Locale string `help:"Content locale for localized shipping rate fields"`
File string `help:"Read shipping rate JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=Express, price:=12.5)"`
}
ShippingRatesUpdateCmd updates a shipping rate.
type SitesCmd ¶
type SitesCmd struct {
List SitesListCmd `cmd:"" help:"List accessible sites"`
Get SitesGetCmd `cmd:"" help:"Get site details"`
Current SitesCurrentCmd `cmd:"" help:"Show current site context"`
Count SitesCountCmd `cmd:"" help:"Count accessible sites"`
Settings SitesSettingsCmd `cmd:"" help:"Get site settings"`
Copy SitesCopyCmd `cmd:"" help:"Copy site configuration and content between sites"`
}
SitesCmd manages sites.
type SitesCopyCmd ¶
type SitesCopyCmd struct {
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
EntryChannels string `help:"Comma-separated channels whose entries should also be copied" name:"entry-channels"`
Only string `help:"Comma-separated channel allowlist when using --recursive"`
Recursive bool `help:"Recursively copy dependent channel entries"`
Upsert string `help:"Comma-separated upsert fields for entry-copy stage"`
CopyCustomers bool `name:"copy-customers" help:"Copy related customers when copying channel entries"`
AllowErrors bool `name:"allow-errors" help:"Continue on item-level validation errors during record copy"`
DryRun bool `name:"dry-run" help:"Show what would be copied without writing to target site"`
SkipCloudCode bool `name:"skip-cloud-code" help:"Skip copying cloud code app files"`
}
SitesCopyCmd copies major site resources between sites.
type SitesCountCmd ¶
type SitesCountCmd struct {
CountQueryFlags `embed:""`
}
SitesCountCmd gets site count.
type SitesCurrentCmd ¶
type SitesCurrentCmd struct{}
SitesCurrentCmd shows the current site context.
type SitesListCmd ¶
type SitesListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
SitesListCmd lists accessible sites.
type ThemeAssetsCmd ¶
type ThemeAssetsCmd struct {
List ThemeAssetsListCmd `cmd:"" help:"List assets"`
Get ThemeAssetsGetCmd `cmd:"" help:"Get an asset"`
Create ThemeAssetsCreateCmd `cmd:"" help:"Create or update an asset"`
Delete ThemeAssetsDeleteCmd `cmd:"" help:"Delete an asset"`
}
ThemeAssetsCmd manages theme assets.
type ThemeAssetsCreateCmd ¶
type ThemeAssetsCreateCmd struct {
Theme string `required:"" help:"Theme ID"`
Name string `required:"" help:"Asset name or path"`
File string `help:"Read asset content from file" short:"f"`
ContentType string `help:"Asset content type"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. source.content_type=text/css)"`
}
ThemeAssetsCreateCmd creates or updates an asset.
type ThemeAssetsDeleteCmd ¶
type ThemeAssetsDeleteCmd struct {
Theme string `required:"" help:"Theme ID"`
Path string `required:"" help:"Asset path"`
}
ThemeAssetsDeleteCmd deletes an asset.
type ThemeAssetsGetCmd ¶
type ThemeAssetsGetCmd struct {
Theme string `required:"" help:"Theme ID"`
Path string `required:"" aliases:"asset" help:"Asset path"`
}
ThemeAssetsGetCmd gets an asset.
type ThemeAssetsListCmd ¶
type ThemeAssetsListCmd struct {
QueryFlags `embed:""`
Theme string `required:"" help:"Theme ID"`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
ThemeAssetsListCmd lists theme assets.
type ThemeCopyCmd ¶
type ThemeCopyCmd struct {
From string `help:"Source site[/theme]" required:"" name:"from"`
To string `help:"Target site[/theme]" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
LiquidOnly bool `help:"Only copy liquid resources" name:"liquid-only"`
}
ThemeCopyCmd copies a theme between sites/themes.
type ThemeDiffCmd ¶
type ThemeDiffCmd struct {
Theme string `help:"Override theme from nimbu.yml"`
Content bool `help:"Show line-by-line changes for each file, like git diff"`
}
ThemeDiffCmd compares local liquid files with the remote theme.
type ThemeFilesCmd ¶
type ThemeFilesCmd struct {
List ThemeFilesListCmd `cmd:"" help:"List theme files"`
Get ThemeFilesGetCmd `cmd:"" help:"Get/download theme file content"`
Put ThemeFilesPutCmd `cmd:"" help:"Upload/update theme file"`
Delete ThemeFilesDeleteCmd `cmd:"" help:"Delete theme file"`
}
ThemeFilesCmd manages theme files.
type ThemeFilesDeleteCmd ¶
type ThemeFilesDeleteCmd struct {
Theme string `required:"" help:"Theme ID"`
Path string `required:"" help:"File path within theme"`
}
ThemeFilesDeleteCmd deletes a theme file.
type ThemeFilesGetCmd ¶
type ThemeFilesGetCmd struct {
Theme string `required:"" help:"Theme ID"`
Path string `required:"" help:"File path within theme"`
Output string `help:"Write file to path instead of stdout" short:"o"`
}
ThemeFilesGetCmd gets/downloads a theme file.
type ThemeFilesListCmd ¶
type ThemeFilesListCmd struct {
QueryFlags `embed:""`
Theme string `required:"" help:"Theme ID"`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
ThemeFilesListCmd lists theme files.
type ThemeFilesPutCmd ¶
type ThemeFilesPutCmd struct {
Theme string `required:"" help:"Theme ID"`
Path string `required:"" help:"File path within theme"`
File string `help:"Read content from file path" short:"f"`
Content string `help:"File content (base64 for binary)" short:"c"`
}
ThemeFilesPutCmd uploads/updates a theme file.
type ThemeLayoutsCmd ¶
type ThemeLayoutsCmd struct {
List ThemeLayoutsListCmd `cmd:"" help:"List layouts"`
Get ThemeLayoutsGetCmd `cmd:"" help:"Get a layout"`
Create ThemeLayoutsCreateCmd `cmd:"" help:"Create or update a layout"`
Delete ThemeLayoutsDeleteCmd `cmd:"" help:"Delete a layout"`
}
ThemeLayoutsCmd manages theme layouts.
type ThemeLayoutsCreateCmd ¶
type ThemeLayoutsCreateCmd struct {
Theme string `required:"" help:"Theme ID"`
Name string `required:"" help:"Layout name including extension"`
File string `help:"Read layout code from file" short:"f"`
Code string `help:"Layout code (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. folder=default)"`
}
ThemeLayoutsCreateCmd creates or updates a layout.
type ThemeLayoutsDeleteCmd ¶
type ThemeLayoutsDeleteCmd struct {
Theme string `required:"" help:"Theme ID"`
Name string `required:"" help:"Layout name including extension"`
}
ThemeLayoutsDeleteCmd deletes a layout.
type ThemeLayoutsGetCmd ¶
type ThemeLayoutsGetCmd struct {
Theme string `required:"" help:"Theme ID"`
Name string `required:"" aliases:"layout" help:"Layout name including extension"`
}
ThemeLayoutsGetCmd gets a layout.
type ThemeLayoutsListCmd ¶
type ThemeLayoutsListCmd struct {
QueryFlags `embed:""`
Theme string `required:"" help:"Theme ID"`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
ThemeLayoutsListCmd lists theme layouts.
type ThemePullCmd ¶
type ThemePullCmd struct {
Theme string `help:"Override theme from nimbu.yml"`
LiquidOnly bool `help:"Only download liquid resources" name:"liquid-only"`
}
ThemePullCmd downloads managed remote theme files.
type ThemePushCmd ¶
type ThemePushCmd struct {
All bool `help:"Upload all managed theme files"`
Build bool `help:"Run sync.build before collecting files"`
DryRun bool `help:"Print planned uploads without changing remote state" name:"dry-run"`
Since string `help:"Compare against this git ref instead of HEAD (e.g. origin/main)"`
Theme string `help:"Override theme from nimbu.yml"`
Only []string `help:"Only upload these file, directory, or glob selectors; commas split multiple selectors" name:"only"`
LiquidOnly bool `help:"Only upload liquid resources" name:"liquid-only"`
CSSOnly bool `help:"Only upload stylesheet assets" name:"css-only"`
JSOnly bool `help:"Only upload JavaScript assets" name:"js-only"`
ImagesOnly bool `help:"Only upload image assets" name:"images-only"`
FontsOnly bool `help:"Only upload font assets" name:"fonts-only"`
NoImages bool `help:"Exclude image assets" name:"no-images"`
NoDeps bool `help:"Do not auto-add Liquid snippet/layout dependencies of --only files" name:"no-deps"`
}
ThemePushCmd uploads managed local theme files without deleting remote files.
type ThemeSnippetsCmd ¶
type ThemeSnippetsCmd struct {
List ThemeSnippetsListCmd `cmd:"" help:"List snippets"`
Get ThemeSnippetsGetCmd `cmd:"" help:"Get a snippet"`
Create ThemeSnippetsCreateCmd `cmd:"" help:"Create or update a snippet"`
Delete ThemeSnippetsDeleteCmd `cmd:"" help:"Delete a snippet"`
}
ThemeSnippetsCmd manages theme snippets.
type ThemeSnippetsCreateCmd ¶
type ThemeSnippetsCreateCmd struct {
Theme string `required:"" help:"Theme ID"`
Name string `required:"" help:"Snippet name including extension"`
File string `help:"Read snippet code from file" short:"f"`
Code string `help:"Snippet code (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. folder=shared)"`
}
ThemeSnippetsCreateCmd creates or updates a snippet.
type ThemeSnippetsDeleteCmd ¶
type ThemeSnippetsDeleteCmd struct {
Theme string `required:"" help:"Theme ID"`
Name string `required:"" help:"Snippet name including extension"`
}
ThemeSnippetsDeleteCmd deletes a snippet.
type ThemeSnippetsGetCmd ¶
type ThemeSnippetsGetCmd struct {
Theme string `required:"" help:"Theme ID"`
Name string `required:"" aliases:"snippet" help:"Snippet name including extension"`
}
ThemeSnippetsGetCmd gets a snippet.
type ThemeSnippetsListCmd ¶
type ThemeSnippetsListCmd struct {
QueryFlags `embed:""`
Theme string `required:"" help:"Theme ID"`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
ThemeSnippetsListCmd lists theme snippets.
type ThemeSyncCmd ¶
type ThemeSyncCmd struct {
All bool `help:"Upload all managed theme files"`
Build bool `help:"Run sync.build before collecting files"`
DryRun bool `help:"Print planned uploads/deletes without changing remote state" name:"dry-run"`
Prune bool `help:"Delete managed remote theme files missing locally"`
Since string `help:"Compare against this git ref instead of HEAD (e.g. origin/main)"`
Theme string `help:"Override theme from nimbu.yml"`
Only []string `help:"Only sync these file, directory, or glob selectors; commas split multiple selectors" name:"only"`
LiquidOnly bool `help:"Only sync liquid resources" name:"liquid-only"`
CSSOnly bool `help:"Only sync stylesheet assets" name:"css-only"`
JSOnly bool `help:"Only sync JavaScript assets" name:"js-only"`
ImagesOnly bool `help:"Only sync image assets" name:"images-only"`
FontsOnly bool `help:"Only sync font assets" name:"fonts-only"`
NoImages bool `help:"Exclude image assets" name:"no-images"`
NoDeps bool `help:"Do not auto-add Liquid snippet/layout dependencies of --only files" name:"no-deps"`
}
ThemeSyncCmd uploads managed local theme files and optionally deletes remote files.
type ThemeTemplatesCmd ¶
type ThemeTemplatesCmd struct {
List ThemeTemplatesListCmd `cmd:"" help:"List templates"`
Get ThemeTemplatesGetCmd `cmd:"" help:"Get a template"`
Create ThemeTemplatesCreateCmd `cmd:"" help:"Create or update a template"`
Delete ThemeTemplatesDeleteCmd `cmd:"" help:"Delete a template"`
}
ThemeTemplatesCmd manages theme templates.
type ThemeTemplatesCreateCmd ¶
type ThemeTemplatesCreateCmd struct {
Theme string `required:"" help:"Theme ID"`
Name string `required:"" help:"Template name including extension"`
File string `help:"Read template code from file" short:"f"`
Code string `help:"Template code (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. folder=emails)"`
}
ThemeTemplatesCreateCmd creates or updates a template.
type ThemeTemplatesDeleteCmd ¶
type ThemeTemplatesDeleteCmd struct {
Theme string `required:"" help:"Theme ID"`
Name string `required:"" help:"Template name including extension"`
}
ThemeTemplatesDeleteCmd deletes a template.
type ThemeTemplatesGetCmd ¶
type ThemeTemplatesGetCmd struct {
Theme string `required:"" help:"Theme ID"`
Name string `required:"" aliases:"template" help:"Template name including extension"`
}
ThemeTemplatesGetCmd gets a template.
type ThemeTemplatesListCmd ¶
type ThemeTemplatesListCmd struct {
QueryFlags `embed:""`
Theme string `required:"" help:"Theme ID"`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
ThemeTemplatesListCmd lists theme templates.
type ThemesCDNRootCmd ¶
type ThemesCDNRootCmd struct {
Theme string `help:"Override theme from nimbu.yml"`
}
ThemesCDNRootCmd prints the resolved CDN root for the configured theme.
type ThemesCmd ¶
type ThemesCmd struct {
List ThemesListCmd `cmd:"" help:"List themes"`
Get ThemesGetCmd `cmd:"" help:"Get theme details"`
CDNRoot ThemesCDNRootCmd `cmd:"" name:"cdn-root" help:"Print the resolved theme CDN root"`
Pull ThemePullCmd `cmd:"" help:"Download managed remote theme files"`
Diff ThemeDiffCmd `cmd:"" help:"Compare remote liquid theme files to local files"`
Copy ThemeCopyCmd `cmd:"" help:"Copy a theme between sites/themes"`
Push ThemePushCmd `cmd:"" help:"Upload managed local theme files"`
Sync ThemeSyncCmd `cmd:"" help:"Upload and reconcile managed local theme files"`
Layouts ThemeLayoutsCmd `cmd:"" help:"Manage layouts"`
Templates ThemeTemplatesCmd `cmd:"" help:"Manage templates"`
Snippets ThemeSnippetsCmd `cmd:"" help:"Manage snippets"`
Assets ThemeAssetsCmd `cmd:"" help:"Manage assets"`
Files ThemeFilesCmd `cmd:"" help:"Manage theme files (undocumented in API overview)"`
}
ThemesCmd manages themes.
type ThemesGetCmd ¶
type ThemesGetCmd struct {
Theme string `required:"" help:"Theme ID"`
}
ThemesGetCmd gets theme details.
type ThemesListCmd ¶
type ThemesListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
ThemesListCmd lists themes.
type TranslationsCmd ¶
type TranslationsCmd struct {
List TranslationsListCmd `cmd:"" help:"List translations"`
Get TranslationsGetCmd `cmd:"" help:"Get translation by key"`
Create TranslationsCreateCmd `cmd:"" help:"Create a translation"`
Update TranslationsUpdateCmd `cmd:"" help:"Update a translation"`
Delete TranslationsDeleteCmd `cmd:"" help:"Delete a translation"`
Count TranslationsCountCmd `cmd:"" help:"Count translations"`
Copy TranslationsCopyCmd `cmd:"" help:"Copy translations between sites"`
}
TranslationsCmd manages translations.
type TranslationsCopyCmd ¶
type TranslationsCopyCmd struct {
Query string `help:"Translation key, prefix*, or *" default:"*" name:"only"`
From string `help:"Source site" required:"" name:"from"`
To string `help:"Target site" required:"" name:"to"`
FromHost string `help:"Source API base URL or host" name:"from-host"`
ToHost string `help:"Target API base URL or host" name:"to-host"`
Since string `help:"Only copy translations updated since RFC3339 or relative duration like 1d"`
DryRun bool `name:"dry-run" help:"Show what would be copied without writing target state"`
}
TranslationsCopyCmd copies translations between sites.
type TranslationsCountCmd ¶
type TranslationsCountCmd struct {
CountQueryFlags `embed:""`
}
TranslationsCountCmd gets translation count.
type TranslationsCreateCmd ¶
type TranslationsCreateCmd struct {
File string `help:"Read translation JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. key=home.title, nl=Welkom, values.fr=Bienvenue)"`
}
TranslationsCreateCmd creates a translation.
type TranslationsDeleteCmd ¶
type TranslationsDeleteCmd struct {
Key string `required:"" help:"Translation key"`
}
TranslationsDeleteCmd deletes a translation.
type TranslationsGetCmd ¶
type TranslationsGetCmd struct {
Key string `required:"" help:"Translation key"`
}
TranslationsGetCmd gets a translation.
type TranslationsListCmd ¶
type TranslationsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
TranslationsListCmd lists translations.
type TranslationsUpdateCmd ¶
type TranslationsUpdateCmd struct {
Key string `required:"" help:"Translation key"`
File string `help:"Read translation JSON from file (use - for stdin)"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. nl=Achternaam, values.fr=Nom)"`
}
TranslationsUpdateCmd updates a translation.
type UploadsCmd ¶
type UploadsCmd struct {
List UploadsListCmd `cmd:"" help:"List uploads"`
Get UploadsGetCmd `cmd:"" help:"Get upload details"`
Create UploadsCreateCmd `cmd:"" help:"Upload a file"`
Download UploadsDownloadCmd `cmd:"" help:"Download an upload"`
Delete UploadsDeleteCmd `cmd:"" help:"Delete an upload"`
Count UploadsCountCmd `cmd:"" help:"Count uploads"`
}
UploadsCmd manages uploads.
type UploadsCountCmd ¶
type UploadsCountCmd struct {
CountQueryFlags `embed:""`
}
UploadsCountCmd gets upload count.
type UploadsCreateCmd ¶
type UploadsCreateCmd struct {
Source string `optional:"" help:"Path to file to upload" name:"source"`
File string `name:"file" short:"f" help:"Path to file to upload"`
FileRef string `name:"file-ref" help:"Nimbu FileRef URI to copy (e.g. nimbu://site/uploads/id)"`
Name string `help:"Override filename" short:"n"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. name=custom.jpg)"`
}
UploadsCreateCmd uploads a file.
type UploadsDeleteCmd ¶
type UploadsDeleteCmd struct {
ID string `required:"" help:"Upload ID"`
}
UploadsDeleteCmd deletes an upload.
type UploadsDownloadCmd ¶ added in v0.3.0
type UploadsGetCmd ¶
type UploadsGetCmd struct {
ID string `required:"" help:"Upload ID"`
}
UploadsGetCmd gets upload details.
type UploadsListCmd ¶
type UploadsListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
UploadsListCmd lists uploads.
type WebhooksCmd ¶
type WebhooksCmd struct {
List WebhooksListCmd `cmd:"" help:"List webhooks"`
Get WebhooksGetCmd `cmd:"" help:"Get webhook details"`
Delete WebhooksDeleteCmd `cmd:"" help:"Delete a webhook"`
}
WebhooksCmd manages webhooks.
type WebhooksCountCmd ¶
type WebhooksCountCmd struct {
CountQueryFlags `embed:""`
}
WebhooksCountCmd gets webhook count.
type WebhooksCreateCmd ¶
type WebhooksCreateCmd struct {
File string `help:"Read webhook data from file (use - for stdin)" short:"f"`
URL string `help:"Webhook URL"`
Events string `help:"Comma-separated event types"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. url=https://example.com, events:=[\"order.created\"])"`
}
WebhooksCreateCmd creates a webhook.
type WebhooksDeleteCmd ¶
type WebhooksDeleteCmd struct {
ID string `required:"" help:"Webhook ID"`
}
WebhooksDeleteCmd deletes a webhook.
type WebhooksGetCmd ¶
type WebhooksGetCmd struct {
ID string `required:"" help:"Webhook ID"`
}
WebhooksGetCmd gets webhook details.
type WebhooksListCmd ¶
type WebhooksListCmd struct {
QueryFlags `embed:""`
All bool `help:"Fetch all pages"`
Page int `help:"Page number" default:"1"`
PerPage int `help:"Items per page" default:"25"`
}
WebhooksListCmd lists webhooks.
type WebhooksUpdateCmd ¶
type WebhooksUpdateCmd struct {
ID string `required:"" help:"Webhook ID"`
File string `help:"Read webhook data from file (use - for stdin)" short:"f"`
Assignments []string `arg:"" optional:"" help:"Inline assignments (e.g. url=https://example.com, active:=true)"`
}
WebhooksUpdateCmd updates a webhook.
Source Files
¶
- admin_helpers.go
- admin_workflows.go
- api.go
- apps.go
- apps_code.go
- apps_code_create.go
- apps_code_list.go
- apps_code_pull.go
- apps_code_resource.go
- apps_config.go
- apps_create.go
- apps_get.go
- apps_list.go
- apps_logs.go
- apps_push.go
- apps_update.go
- audited_helpers.go
- auth.go
- auth_credentials.go
- auth_keyring.go
- auth_login.go
- auth_login_oauth.go
- auth_logout.go
- auth_scopes.go
- auth_session.go
- auth_status.go
- auth_token.go
- auth_whoami.go
- banner_themes.go
- blogs.go
- blogs_copy.go
- blogs_count.go
- blogs_create.go
- blogs_delete.go
- blogs_get.go
- blogs_list.go
- blogs_posts.go
- blogs_posts_count.go
- blogs_posts_create.go
- blogs_posts_delete.go
- blogs_posts_get.go
- blogs_posts_list.go
- blogs_posts_update.go
- blogs_update.go
- channels.go
- channels_copy.go
- channels_create.go
- channels_delete.go
- channels_diff.go
- channels_empty.go
- channels_entries.go
- channels_entries_copy.go
- channels_entries_count.go
- channels_entries_create.go
- channels_entries_delete.go
- channels_entries_gallery.go
- channels_entries_gallery_payload.go
- channels_entries_get.go
- channels_entries_list.go
- channels_entries_update.go
- channels_entries_watch.go
- channels_entries_watch_output.go
- channels_fields.go
- channels_fields_presenter.go
- channels_get.go
- channels_info.go
- channels_list.go
- channels_types.go
- collections.go
- collections_copy.go
- collections_count.go
- collections_create.go
- collections_delete.go
- collections_get.go
- collections_list.go
- collections_update.go
- command_helpers.go
- commands.go
- completion.go
- completion_cache.go
- completion_dynamic.go
- completion_dynamic_sources.go
- config.go
- config_banner.go
- copy_timeline_helpers.go
- coupons.go
- coupons_count.go
- coupons_create.go
- coupons_delete.go
- coupons_get.go
- coupons_list.go
- coupons_update.go
- custom_fields_commands.go
- customer_roles.go
- customers.go
- customers_actions.go
- customers_config.go
- customers_copy.go
- customers_count.go
- customers_create.go
- customers_delete.go
- customers_get.go
- customers_list.go
- customers_update.go
- customizations_copy_diff.go
- domains.go
- domains_commands.go
- env.go
- error_contract.go
- functions.go
- functions_run.go
- help_printer.go
- init.go
- init_prompt.go
- init_tui.go
- init_tui_commands.go
- init_tui_render.go
- inline_assignments.go
- jobs.go
- jobs_list.go
- jobs_run.go
- list_columns.go
- list_footer.go
- list_options.go
- localized_output.go
- mails.go
- menus.go
- menus_copy.go
- menus_count.go
- menus_create.go
- menus_delete.go
- menus_get.go
- menus_list.go
- menus_update.go
- migrate_helpers.go
- notifications.go
- notifications_copy.go
- notifications_count.go
- notifications_create.go
- notifications_delete.go
- notifications_get.go
- notifications_list.go
- notifications_pull.go
- notifications_push.go
- notifications_update.go
- orders.go
- orders_actions.go
- orders_count.go
- orders_get.go
- orders_list.go
- orders_update.go
- pages.go
- pages_batch.go
- pages_copy.go
- pages_count.go
- pages_create.go
- pages_delete.go
- pages_delete_block.go
- pages_draft.go
- pages_draft_snapshot.go
- pages_get.go
- pages_help.go
- pages_insert.go
- pages_items.go
- pages_list.go
- pages_move.go
- pages_schema.go
- pages_set.go
- pages_surgical.go
- pages_surgical_diff.go
- pages_surgical_draft.go
- pages_surgical_output.go
- pages_surgical_resolve.go
- pages_surgical_value.go
- pages_theme_hints.go
- pages_update.go
- pages_versions.go
- product_attachments.go
- products.go
- products_config.go
- products_copy.go
- products_count.go
- products_create.go
- products_delete.go
- products_get.go
- products_list.go
- products_update.go
- project_context.go
- realtime.go
- realtime_grant.go
- redirects.go
- redirects_copy.go
- redirects_create.go
- redirects_delete.go
- redirects_get.go
- redirects_list.go
- redirects_update.go
- release.go
- releases.go
- repeated_csv.go
- rich_contract_helpers.go
- roles.go
- roles_copy.go
- roles_create.go
- roles_customers.go
- roles_delete.go
- roles_get.go
- roles_list.go
- roles_relations.go
- roles_update.go
- root.go
- root_update.go
- schema.go
- schema_apply.go
- schema_cycles.go
- schema_inventory.go
- schema_pull.go
- schema_rename.go
- scope_preflight.go
- senders.go
- senders_commands.go
- server.go
- server_config.go
- server_draft.go
- server_shortcuts.go
- server_shortcuts_input_unix.go
- server_shortcuts_term_unix.go
- server_shortcuts_term_unix_other.go
- server_signal_unix.go
- server_ui.go
- server_ui_urls.go
- settings_consent_config.go
- settings_events.go
- shared_helpers.go
- shipping_rates.go
- sites.go
- sites_copy.go
- sites_count.go
- sites_current.go
- sites_get.go
- sites_list.go
- sites_settings.go
- sync_timeline_helpers.go
- theme_info.go
- theme_resources.go
- themes.go
- themes_assets.go
- themes_assets_create.go
- themes_assets_delete.go
- themes_assets_get.go
- themes_assets_list.go
- themes_cdn_root.go
- themes_copy.go
- themes_diff.go
- themes_files.go
- themes_files_delete.go
- themes_files_get.go
- themes_files_list.go
- themes_files_put.go
- themes_get.go
- themes_layouts.go
- themes_layouts_create.go
- themes_layouts_delete.go
- themes_layouts_get.go
- themes_layouts_list.go
- themes_list.go
- themes_pull.go
- themes_snippets.go
- themes_snippets_create.go
- themes_snippets_delete.go
- themes_snippets_get.go
- themes_snippets_list.go
- themes_sync.go
- themes_templates.go
- themes_templates_create.go
- themes_templates_delete.go
- themes_templates_get.go
- themes_templates_list.go
- translations.go
- translations_copy.go
- translations_count.go
- translations_create.go
- translations_delete.go
- translations_get.go
- translations_list.go
- translations_update.go
- uploads.go
- uploads_count.go
- uploads_create.go
- uploads_delete.go
- uploads_download.go
- uploads_get.go
- uploads_list.go
- webhooks.go
- webhooks_count.go
- webhooks_create.go
- webhooks_delete.go
- webhooks_get.go
- webhooks_list.go
- webhooks_update.go