Documentation ¶
Overview ¶
Generated service client for heroku API.
To be able to interact with this API, you have to create a new service:
s := heroku.NewService(nil)
The Service struct has all the methods you need to interact with heroku API.
Index ¶
- Constants
- Variables
- func Bool(v bool) *bool
- func Float64(v float64) *float64
- func Int(v int) *int
- func String(v string) *string
- type Account
- type AccountChangeEmailOpts
- type AccountChangePasswordOpts
- type AccountFeature
- type AccountFeatureUpdateOpts
- type AccountUpdateOpts
- type Addon
- type AddonCreateOpts
- type AddonService
- type AddonUpdateOpts
- type App
- type AppCreateOpts
- type AppFeature
- type AppFeatureUpdateOpts
- type AppSetup
- type AppSetupCreateOpts
- type AppTransfer
- type AppTransferCreateOpts
- type AppTransferUpdateOpts
- type AppUpdateOpts
- type Build
- type BuildCreateOpts
- type BuildResult
- type Collaborator
- type CollaboratorCreateOpts
- type ConfigVar
- type ConfigVarUpdateOpts
- type Credit
- type Domain
- type DomainCreateOpts
- type Dyno
- type DynoCreateOpts
- type Error
- type Formation
- type FormationBatchUpdateOpts
- type FormationUpdateOpts
- type Key
- type KeyCreateOpts
- type ListRange
- type LogDrain
- type LogDrainCreateOpts
- type LogSession
- type LogSessionCreateOpts
- type OAuthAuthorization
- type OAuthAuthorizationCreateOpts
- type OAuthClient
- type OAuthClientCreateOpts
- type OAuthClientUpdateOpts
- type OAuthGrant
- type OAuthToken
- type OAuthTokenCreateOpts
- type Organization
- type OrganizationApp
- type OrganizationAppCollaborator
- type OrganizationAppCollaboratorCreateOpts
- type OrganizationAppCreateOpts
- type OrganizationAppTransferToAccountOpts
- type OrganizationAppTransferToOrganizationOpts
- type OrganizationAppUpdateLockedOpts
- type OrganizationMember
- type OrganizationMemberCreateOrUpdateOpts
- type OrganizationUpdateOpts
- type Plan
- type RateLimit
- type Region
- type Release
- type ReleaseCreateOpts
- type ReleaseRollbackOpts
- type SSLEndpoint
- type SSLEndpointCreateOpts
- type SSLEndpointUpdateOpts
- type Service
- func (s *Service) AccountChangeEmail(o struct{ ... }) (*Account, error)
- func (s *Service) AccountChangePassword(o struct{ ... }) (*Account, error)
- func (s *Service) AccountFeatureInfo(accountFeatureIdentity string) (*AccountFeature, error)
- func (s *Service) AccountFeatureList(lr *ListRange) ([]*AccountFeature, error)
- func (s *Service) AccountFeatureUpdate(accountFeatureIdentity string, o struct{ ... }) (*AccountFeature, error)
- func (s *Service) AccountInfo() (*Account, error)
- func (s *Service) AccountUpdate(o struct{ ... }) (*Account, error)
- func (s *Service) AddonCreate(appIdentity string, o struct{ ... }) (*Addon, error)
- func (s *Service) AddonDelete(appIdentity string, addonIdentity string) error
- func (s *Service) AddonInfo(appIdentity string, addonIdentity string) (*Addon, error)
- func (s *Service) AddonList(appIdentity string, lr *ListRange) ([]*Addon, error)
- func (s *Service) AddonServiceInfo(addonServiceIdentity string) (*AddonService, error)
- func (s *Service) AddonServiceList(lr *ListRange) ([]*AddonService, error)
- func (s *Service) AddonUpdate(appIdentity string, addonIdentity string, o struct{ ... }) (*Addon, error)
- func (s *Service) AppCreate(o struct{ ... }) (*App, error)
- func (s *Service) AppDelete(appIdentity string) error
- func (s *Service) AppFeatureInfo(appIdentity string, appFeatureIdentity string) (*AppFeature, error)
- func (s *Service) AppFeatureList(appIdentity string, lr *ListRange) ([]*AppFeature, error)
- func (s *Service) AppFeatureUpdate(appIdentity string, appFeatureIdentity string, o struct{ ... }) (*AppFeature, error)
- func (s *Service) AppInfo(appIdentity string) (*App, error)
- func (s *Service) AppList(lr *ListRange) ([]*App, error)
- func (s *Service) AppSetupCreate(o struct{ ... }) (*AppSetup, error)
- func (s *Service) AppSetupInfo(appSetupIdentity string) (*AppSetup, error)
- func (s *Service) AppTransferCreate(o struct{ ... }) (*AppTransfer, error)
- func (s *Service) AppTransferDelete(appTransferIdentity string) error
- func (s *Service) AppTransferInfo(appTransferIdentity string) (*AppTransfer, error)
- func (s *Service) AppTransferList(lr *ListRange) ([]*AppTransfer, error)
- func (s *Service) AppTransferUpdate(appTransferIdentity string, o struct{ ... }) (*AppTransfer, error)
- func (s *Service) AppUpdate(appIdentity string, o struct{ ... }) (*App, error)
- func (s *Service) BuildCreate(appIdentity string, o struct{ ... }) (*Build, error)
- func (s *Service) BuildInfo(appIdentity string, buildIdentity string) (*Build, error)
- func (s *Service) BuildList(appIdentity string, lr *ListRange) ([]*Build, error)
- func (s *Service) BuildResultInfo(appIdentity string, buildIdentity string) (*BuildResult, error)
- func (s *Service) CollaboratorCreate(appIdentity string, o struct{ ... }) (*Collaborator, error)
- func (s *Service) CollaboratorDelete(appIdentity string, collaboratorIdentity string) error
- func (s *Service) CollaboratorInfo(appIdentity string, collaboratorIdentity string) (*Collaborator, error)
- func (s *Service) CollaboratorList(appIdentity string, lr *ListRange) ([]*Collaborator, error)
- func (s *Service) ConfigVarInfo(appIdentity string) (map[string]string, error)
- func (s *Service) ConfigVarUpdate(appIdentity string, o map[string]*string) (map[string]string, error)
- func (s *Service) CreditInfo(creditIdentity string) (*Credit, error)
- func (s *Service) CreditList(lr *ListRange) ([]*Credit, error)
- func (s *Service) Delete(path string) error
- func (s *Service) Do(v interface{}, method, path string, body interface{}, lr *ListRange) error
- func (s *Service) DomainCreate(appIdentity string, o struct{ ... }) (*Domain, error)
- func (s *Service) DomainDelete(appIdentity string, domainIdentity string) error
- func (s *Service) DomainInfo(appIdentity string, domainIdentity string) (*Domain, error)
- func (s *Service) DomainList(appIdentity string, lr *ListRange) ([]*Domain, error)
- func (s *Service) DynoCreate(appIdentity string, o struct{ ... }) (*Dyno, error)
- func (s *Service) DynoInfo(appIdentity string, dynoIdentity string) (*Dyno, error)
- func (s *Service) DynoList(appIdentity string, lr *ListRange) ([]*Dyno, error)
- func (s *Service) DynoRestart(appIdentity string, dynoIdentity string) error
- func (s *Service) DynoRestartAll(appIdentity string) error
- func (s *Service) FormationBatchUpdate(appIdentity string, o struct{ ... }) (*Formation, error)
- func (s *Service) FormationInfo(appIdentity string, formationIdentity string) (*Formation, error)
- func (s *Service) FormationList(appIdentity string, lr *ListRange) ([]*Formation, error)
- func (s *Service) FormationUpdate(appIdentity string, formationIdentity string, o struct{ ... }) (*Formation, error)
- func (s *Service) Get(v interface{}, path string, lr *ListRange) error
- func (s *Service) KeyCreate(o struct{ ... }) (*Key, error)
- func (s *Service) KeyDelete(keyIdentity string) error
- func (s *Service) KeyInfo(keyIdentity string) (*Key, error)
- func (s *Service) KeyList(lr *ListRange) ([]*Key, error)
- func (s *Service) LogDrainCreate(appIdentity string, o struct{ ... }) (*LogDrain, error)
- func (s *Service) LogDrainDelete(appIdentity string, logDrainIdentity string) error
- func (s *Service) LogDrainInfo(appIdentity string, logDrainIdentity string) (*LogDrain, error)
- func (s *Service) LogDrainList(appIdentity string, lr *ListRange) ([]*LogDrain, error)
- func (s *Service) LogSessionCreate(appIdentity string, o struct{ ... }) (*LogSession, error)
- func (s *Service) NewRequest(method, path string, body interface{}) (*http.Request, error)
- func (s *Service) OAuthAuthorizationCreate(o struct{ ... }) (*OAuthAuthorization, error)
- func (s *Service) OAuthAuthorizationDelete(oauthAuthorizationIdentity string) error
- func (s *Service) OAuthAuthorizationInfo(oauthAuthorizationIdentity string) (*OAuthAuthorization, error)
- func (s *Service) OAuthAuthorizationList(lr *ListRange) ([]*OAuthAuthorization, error)
- func (s *Service) OAuthClientCreate(o struct{ ... }) (*OAuthClient, error)
- func (s *Service) OAuthClientDelete(oauthClientIdentity string) error
- func (s *Service) OAuthClientInfo(oauthClientIdentity string) (*OAuthClient, error)
- func (s *Service) OAuthClientList(lr *ListRange) ([]*OAuthClient, error)
- func (s *Service) OAuthClientUpdate(oauthClientIdentity string, o struct{ ... }) (*OAuthClient, error)
- func (s *Service) OAuthTokenCreate(o struct{ ... }) (*OAuthToken, error)
- func (s *Service) OrganizationAppCollaboratorCreate(appIdentity string, o struct{ ... }) (*OrganizationAppCollaborator, error)
- func (s *Service) OrganizationAppCollaboratorDelete(organizationAppIdentity string, organizationAppCollaboratorIdentity string) error
- func (s *Service) OrganizationAppCollaboratorInfo(organizationAppIdentity string, organizationAppCollaboratorIdentity string) (*OrganizationAppCollaborator, error)
- func (s *Service) OrganizationAppCollaboratorList(organizationAppIdentity string, lr *ListRange) ([]*OrganizationAppCollaborator, error)
- func (s *Service) OrganizationAppCreate(o struct{ ... }) (*OrganizationApp, error)
- func (s *Service) OrganizationAppInfo(organizationAppIdentity string) (*OrganizationApp, error)
- func (s *Service) OrganizationAppList(lr *ListRange) ([]*OrganizationApp, error)
- func (s *Service) OrganizationAppListForOrganization(organizationIdentity string, lr *ListRange) ([]*OrganizationApp, error)
- func (s *Service) OrganizationAppTransferToAccount(organizationAppIdentity string, o struct{ ... }) (*OrganizationApp, error)
- func (s *Service) OrganizationAppTransferToOrganization(organizationAppIdentity string, o struct{ ... }) (*OrganizationApp, error)
- func (s *Service) OrganizationAppUpdateLocked(organizationAppIdentity string, o struct{ ... }) (*OrganizationApp, error)
- func (s *Service) OrganizationList(lr *ListRange) ([]*Organization, error)
- func (s *Service) OrganizationMemberCreateOrUpdate(organizationIdentity string, o struct{ ... }) (*OrganizationMember, error)
- func (s *Service) OrganizationMemberDelete(organizationIdentity string, organizationMemberIdentity string) error
- func (s *Service) OrganizationMemberList(organizationIdentity string, lr *ListRange) ([]*OrganizationMember, error)
- func (s *Service) OrganizationUpdate(organizationIdentity string, o struct{ ... }) (*Organization, error)
- func (s *Service) Patch(v interface{}, path string, body interface{}) error
- func (s *Service) PlanInfo(addonServiceIdentity string, planIdentity string) (*Plan, error)
- func (s *Service) PlanList(addonServiceIdentity string, lr *ListRange) ([]*Plan, error)
- func (s *Service) Post(v interface{}, path string, body interface{}) error
- func (s *Service) Put(v interface{}, path string, body interface{}) error
- func (s *Service) RateLimitInfo() (*RateLimit, error)
- func (s *Service) RegionInfo(regionIdentity string) (*Region, error)
- func (s *Service) RegionList(lr *ListRange) ([]*Region, error)
- func (s *Service) ReleaseCreate(appIdentity string, o struct{ ... }) (*Release, error)
- func (s *Service) ReleaseInfo(appIdentity string, releaseIdentity string) (*Release, error)
- func (s *Service) ReleaseList(appIdentity string, lr *ListRange) ([]*Release, error)
- func (s *Service) ReleaseRollback(appIdentity string, o struct{ ... }) (*Release, error)
- func (s *Service) SSLEndpointCreate(appIdentity string, o struct{ ... }) (*SSLEndpoint, error)
- func (s *Service) SSLEndpointDelete(appIdentity string, sslEndpointIdentity string) error
- func (s *Service) SSLEndpointInfo(appIdentity string, sslEndpointIdentity string) (*SSLEndpoint, error)
- func (s *Service) SSLEndpointList(appIdentity string, lr *ListRange) ([]*SSLEndpoint, error)
- func (s *Service) SSLEndpointUpdate(appIdentity string, sslEndpointIdentity string, o struct{ ... }) (*SSLEndpoint, error)
- func (s *Service) SlugCreate(appIdentity string, o struct{ ... }) (*Slug, error)
- func (s *Service) SlugInfo(appIdentity string, slugIdentity string) (*Slug, error)
- func (s *Service) StackInfo(stackIdentity string) (*Stack, error)
- func (s *Service) StackList(lr *ListRange) ([]*Stack, error)
- type Slug
- type SlugCreateOpts
- type Stack
- type Transport
Constants ¶
Variables ¶
var DefaultClient = &http.Client{ Transport: DefaultTransport, }
var DefaultTransport = &Transport{}
Functions ¶
Types ¶
type Account ¶
type Account struct { AllowTracking bool `json:"allow_tracking"` // whether to allow third party web activity tracking Beta bool `json:"beta"` // whether allowed to utilize beta Heroku features CreatedAt time.Time `json:"created_at"` // when account was created Email string `json:"email"` // unique email address of account ID string `json:"id"` // unique identifier of an account LastLogin time.Time `json:"last_login"` // when account last authorized with Heroku Name *string `json:"name"` // full name of the account owner UpdatedAt time.Time `json:"updated_at"` // when account was updated Verified bool `json:"verified"` // whether account has been verified with billing information }
An account represents an individual signed up to use the Heroku platform.
type AccountChangeEmailOpts ¶
type AccountFeature ¶
type AccountFeature struct { CreatedAt time.Time `json:"created_at"` // when account feature was created Description string `json:"description"` // description of account feature DocURL string `json:"doc_url"` // documentation URL of account feature Enabled bool `json:"enabled"` // whether or not account feature has been enabled ID string `json:"id"` // unique identifier of account feature Name string `json:"name"` // unique name of account feature State string `json:"state"` // state of account feature UpdatedAt time.Time `json:"updated_at"` // when account feature was updated }
An account feature represents a Heroku labs capability that can be enabled or disabled for an account on Heroku.
type AccountFeatureUpdateOpts ¶
type AccountFeatureUpdateOpts struct {
Enabled bool `json:"enabled"` // whether or not account feature has been enabled
}
type AccountUpdateOpts ¶
type AccountUpdateOpts struct { AllowTracking *bool `json:"allow_tracking,omitempty"` // whether to allow third party web activity tracking Beta *bool `json:"beta,omitempty"` // whether allowed to utilize beta Heroku features Name *string `json:"name,omitempty"` // full name of the account owner Password string `json:"password"` // current password on the account }
type Addon ¶
type Addon struct { AddonService struct { ID string `json:"id"` // unique identifier of this addon-service Name string `json:"name"` // unique name of this addon-service } `json:"addon_service"` // identity of add-on service ConfigVars []string `json:"config_vars"` // config vars associated with this application CreatedAt time.Time `json:"created_at"` // when add-on was updated ID string `json:"id"` // unique identifier of add-on Name string `json:"name"` // name of the add-on unique within its app Plan struct { ID string `json:"id"` // unique identifier of this plan Name string `json:"name"` // unique name of this plan } `json:"plan"` // identity of add-on plan ProviderID string `json:"provider_id"` // id of this add-on with its provider UpdatedAt time.Time `json:"updated_at"` // when add-on was updated }
Add-ons represent add-ons that have been provisioned for an app.
type AddonCreateOpts ¶
type AddonService ¶
type AddonService struct { CreatedAt time.Time `json:"created_at"` // when addon-service was created ID string `json:"id"` // unique identifier of this addon-service Name string `json:"name"` // unique name of this addon-service UpdatedAt time.Time `json:"updated_at"` // when addon-service was updated }
Add-on services represent add-ons that may be provisioned for apps. Endpoints under add-on services can be accessed without authentication.
type AddonUpdateOpts ¶
type AddonUpdateOpts struct {
Plan string `json:"plan"` // unique identifier of this plan
}
type App ¶
type App struct { ArchivedAt *time.Time `json:"archived_at"` // when app was archived BuildpackProvidedDescription *string `json:"buildpack_provided_description"` // description from buildpack of app CreatedAt time.Time `json:"created_at"` // when app was created GitURL string `json:"git_url"` // git repo URL of app ID string `json:"id"` // unique identifier of app Maintenance bool `json:"maintenance"` // maintenance status of app Name string `json:"name"` // unique name of app Owner struct { Email string `json:"email"` // unique email address of account ID string `json:"id"` // unique identifier of an account } `json:"owner"` // identity of app owner Region struct { ID string `json:"id"` // unique identifier of region Name string `json:"name"` // unique name of region } `json:"region"` // identity of app region ReleasedAt *time.Time `json:"released_at"` // when app was released RepoSize *int `json:"repo_size"` // git repo size in bytes of app SlugSize *int `json:"slug_size"` // slug size in bytes of app Stack struct { ID string `json:"id"` // unique identifier of stack Name string `json:"name"` // unique name of stack } `json:"stack"` // identity of app stack UpdatedAt time.Time `json:"updated_at"` // when app was updated WebURL string `json:"web_url"` // web URL of app }
An app represents the program that you would like to deploy and run on Heroku.
type AppCreateOpts ¶
type AppFeature ¶
type AppFeature struct { CreatedAt time.Time `json:"created_at"` // when app feature was created Description string `json:"description"` // description of app feature DocURL string `json:"doc_url"` // documentation URL of app feature Enabled bool `json:"enabled"` // whether or not app feature has been enabled ID string `json:"id"` // unique identifier of app feature Name string `json:"name"` // unique name of app feature State string `json:"state"` // state of app feature UpdatedAt time.Time `json:"updated_at"` // when app feature was updated }
An app feature represents a Heroku labs capability that can be enabled or disabled for an app on Heroku.
type AppFeatureUpdateOpts ¶
type AppFeatureUpdateOpts struct {
Enabled bool `json:"enabled"` // whether or not app feature has been enabled
}
type AppSetup ¶
type AppSetup struct { App struct { ID string `json:"id"` // unique identifier of app Name string `json:"name"` // unique name of app } `json:"app"` // identity of app Build struct { ID string `json:"id"` // unique identifier of build Status string `json:"status"` // status of build } `json:"build"` // identity and status of build CreatedAt time.Time `json:"created_at"` // when app setup was created FailureMessage *string `json:"failure_message"` // reason that app setup has failed ID string `json:"id"` // unique identifier of app setup ManifestErrors []string `json:"manifest_errors"` // errors associated with invalid app.json manifest file Postdeploy *struct { ExitCode int `json:"exit_code"` // The exit code of the postdeploy script Output string `json:"output"` // output of the postdeploy script } `json:"postdeploy"` // result of postdeploy script ResolvedSuccessURL *string `json:"resolved_success_url"` // fully qualified success url Status string `json:"status"` // the overall status of app setup UpdatedAt time.Time `json:"updated_at"` // when app setup was updated }
An app setup represents an app on Heroku that is setup using an environment, addons, and scripts described in an app.json manifest file.
type AppSetupCreateOpts ¶
type AppSetupCreateOpts struct { App *struct { Locked *bool `json:"locked,omitempty"` // are other organization members forbidden from joining this app. Name *string `json:"name,omitempty"` // unique name of app Organization *string `json:"organization,omitempty"` // unique name of organization Personal *bool `json:"personal,omitempty"` // force creation of the app in the user account even if a default org // is set. Region *string `json:"region,omitempty"` // unique name of region Stack *string `json:"stack,omitempty"` // unique name of stack } `json:"app,omitempty"` // optional parameters for created app Overrides *struct { Env *map[string]string `json:"env,omitempty"` // overrides of the env specified in the app.json manifest file } `json:"overrides,omitempty"` // overrides of keys in the app.json manifest file SourceBlob struct { URL *string `json:"url,omitempty"` // URL of gzipped tarball of source code containing app.json manifest } `json:"source_blob"` // gzipped tarball of source code containing app.json manifest file }
type AppTransfer ¶
type AppTransfer struct { App struct { ID string `json:"id"` // unique identifier of app Name string `json:"name"` // unique name of app } `json:"app"` // app involved in the transfer CreatedAt time.Time `json:"created_at"` // when app transfer was created ID string `json:"id"` // unique identifier of app transfer Owner struct { Email string `json:"email"` // unique email address of account ID string `json:"id"` // unique identifier of an account } `json:"owner"` // identity of the owner of the transfer Recipient struct { Email string `json:"email"` // unique email address of account ID string `json:"id"` // unique identifier of an account } `json:"recipient"` // identity of the recipient of the transfer State string `json:"state"` // the current state of an app transfer UpdatedAt time.Time `json:"updated_at"` // when app transfer was updated }
An app transfer represents a two party interaction for transferring ownership of an app.
type AppTransferCreateOpts ¶
type AppTransferUpdateOpts ¶
type AppTransferUpdateOpts struct {
State string `json:"state"` // the current state of an app transfer
}
type AppUpdateOpts ¶
type Build ¶
type Build struct { CreatedAt time.Time `json:"created_at"` // when build was created ID string `json:"id"` // unique identifier of build Slug *struct { ID string `json:"id"` // unique identifier of slug } `json:"slug"` // slug created by this build SourceBlob struct { URL string `json:"url"` // URL where gzipped tar archive of source code for build was // downloaded. Version *string `json:"version"` // Version of the gzipped tarball. } `json:"source_blob"` // location of gzipped tarball of source code used to create build Status string `json:"status"` // status of build UpdatedAt time.Time `json:"updated_at"` // when build was updated User struct { Email string `json:"email"` // unique email address of account ID string `json:"id"` // unique identifier of an account } `json:"user"` // user that started the build }
A build represents the process of transforming a code tarball into a slug
type BuildCreateOpts ¶
type BuildCreateOpts struct { SourceBlob struct { URL *string `json:"url,omitempty"` // URL where gzipped tar archive of source code for build was // downloaded. Version *string `json:"version,omitempty"` // Version of the gzipped tarball. } `json:"source_blob"` // location of gzipped tarball of source code used to create build }
type BuildResult ¶
type BuildResult struct { Build struct { ID string `json:"id"` // unique identifier of build Status string `json:"status"` // status of build } `json:"build"` // identity of build ExitCode float64 `json:"exit_code"` // status from the build Lines []struct { Line string `json:"line"` // A line of output from the build. Stream string `json:"stream"` // The output stream where the line was sent. } `json:"lines"` // A list of all the lines of a build's output. }
A build result contains the output from a build.
type Collaborator ¶
type Collaborator struct { CreatedAt time.Time `json:"created_at"` // when collaborator was created ID string `json:"id"` // unique identifier of collaborator UpdatedAt time.Time `json:"updated_at"` // when collaborator was updated User struct { Email string `json:"email"` // unique email address of account ID string `json:"id"` // unique identifier of an account } `json:"user"` // identity of collaborated account }
A collaborator represents an account that has been given access to an app on Heroku.
type CollaboratorCreateOpts ¶
type ConfigVar ¶
Config Vars allow you to manage the configuration information provided to an app on Heroku.
type ConfigVarUpdateOpts ¶
type Credit ¶
type Credit struct { Amount float64 `json:"amount"` // total value of credit in cents Balance float64 `json:"balance"` // remaining value of credit in cents CreatedAt time.Time `json:"created_at"` // when credit was created ExpiresAt time.Time `json:"expires_at"` // when credit will expire ID string `json:"id"` // unique identifier of credit Title string `json:"title"` // a name for credit UpdatedAt time.Time `json:"updated_at"` // when credit was updated }
A credit represents value that will be used up before further charges are assigned to an account.
type Domain ¶
type Domain struct { CreatedAt time.Time `json:"created_at"` // when domain was created Hostname string `json:"hostname"` // full hostname ID string `json:"id"` // unique identifier of this domain UpdatedAt time.Time `json:"updated_at"` // when domain was updated }
Domains define what web routes should be routed to an app on Heroku.
type DomainCreateOpts ¶
type DomainCreateOpts struct {
Hostname string `json:"hostname"` // full hostname
}
type Dyno ¶
type Dyno struct { AttachURL *string `json:"attach_url"` // a URL to stream output from for attached processes or null for // non-attached processes Command string `json:"command"` // command used to start this process CreatedAt time.Time `json:"created_at"` // when dyno was created ID string `json:"id"` // unique identifier of this dyno Name string `json:"name"` // the name of this process on this dyno Release struct { ID string `json:"id"` // unique identifier of release Version int `json:"version"` // unique version assigned to the release } `json:"release"` // app release of the dyno Size string `json:"size"` // dyno size (default: "1X") State string `json:"state"` // current status of process (either: crashed, down, idle, starting, or // up) Type string `json:"type"` // type of process UpdatedAt time.Time `json:"updated_at"` // when process last changed state }
Dynos encapsulate running processes of an app on Heroku.
type DynoCreateOpts ¶
type DynoCreateOpts struct { Attach *bool `json:"attach,omitempty"` // whether to stream output or not Command string `json:"command"` // command used to start this process Env *map[string]string `json:"env,omitempty"` // custom environment to add to the dyno config vars Size *string `json:"size,omitempty"` // dyno size (default: "1X") }
type Formation ¶
type Formation struct { Command string `json:"command"` // command to use to launch this process CreatedAt time.Time `json:"created_at"` // when process type was created ID string `json:"id"` // unique identifier of this process type Quantity int `json:"quantity"` // number of processes to maintain Size string `json:"size"` // dyno size (default: "1X") Type string `json:"type"` // type of process to maintain UpdatedAt time.Time `json:"updated_at"` // when dyno type was updated }
The formation of processes that should be maintained for an app. Update the formation to scale processes or change dyno sizes. Available process type names and commands are defined by the `process_types` attribute for the [slug](#slug) currently released on an app.
type FormationBatchUpdateOpts ¶
type FormationBatchUpdateOpts struct { Updates []struct { Process string `json:"process"` // unique identifier of this process type Quantity *int `json:"quantity,omitempty"` // number of processes to maintain Size *string `json:"size,omitempty"` // dyno size (default: "1X") } `json:"updates"` // Array with formation updates. Each element must have "process", the }
type FormationUpdateOpts ¶
type Key ¶
type Key struct { Comment string `json:"comment"` // comment on the key CreatedAt time.Time `json:"created_at"` // when key was created Email string `json:"email"` // deprecated. Please refer to 'comment' instead Fingerprint string `json:"fingerprint"` // a unique identifying string based on contents ID string `json:"id"` // unique identifier of this key PublicKey string `json:"public_key"` // full public_key as uploaded UpdatedAt time.Time `json:"updated_at"` // when key was updated }
Keys represent public SSH keys associated with an account and are used to authorize accounts as they are performing git operations.
type KeyCreateOpts ¶
type KeyCreateOpts struct {
PublicKey string `json:"public_key"` // full public_key as uploaded
}
type LogDrain ¶
type LogDrain struct { Addon *struct { ID string `json:"id"` // unique identifier of add-on } `json:"addon"` // addon that created the drain CreatedAt time.Time `json:"created_at"` // when log drain was created ID string `json:"id"` // unique identifier of this log drain Token string `json:"token"` // token associated with the log drain UpdatedAt time.Time `json:"updated_at"` // when log drain was updated URL string `json:"url"` // url associated with the log drain }
[Log drains](https://devcenter.heroku.com/articles/logging#syslog-drains) provide a way to forward your Heroku logs to an external syslog server for long-term archiving. This external service must be configured to receive syslog packets from Heroku, whereupon its URL can be added to an app using this API. Some addons will add a log drain when they are provisioned to an app. These drains can only be removed by removing the add-on.
type LogDrainCreateOpts ¶
type LogDrainCreateOpts struct {
URL string `json:"url"` // url associated with the log drain
}
type LogSession ¶
type LogSession struct { CreatedAt time.Time `json:"created_at"` // when log connection was created ID string `json:"id"` // unique identifier of this log session LogplexURL string `json:"logplex_url"` // URL for log streaming session UpdatedAt time.Time `json:"updated_at"` // when log session was updated }
A log session is a reference to the http based log stream for an app.
type LogSessionCreateOpts ¶
type LogSessionCreateOpts struct { Dyno *string `json:"dyno,omitempty"` // dyno to limit results to Lines *int `json:"lines,omitempty"` // number of log lines to stream at once Source *string `json:"source,omitempty"` // log source to limit results to Tail *bool `json:"tail,omitempty"` // whether to stream ongoing logs }
type OAuthAuthorization ¶
type OAuthAuthorization struct { AccessToken *struct { ExpiresIn *int `json:"expires_in"` // seconds until OAuth token expires; may be `null` for tokens with // indefinite lifetime ID string `json:"id"` // unique identifier of OAuth token Token string `json:"token"` // contents of the token to be used for authorization } `json:"access_token"` // access token for this authorization Client *struct { ID string `json:"id"` // unique identifier of this OAuth client Name string `json:"name"` // OAuth client name RedirectURI string `json:"redirect_uri"` // endpoint for redirection after authorization with OAuth client } `json:"client"` // identifier of the client that obtained this authorization, if any CreatedAt time.Time `json:"created_at"` // when OAuth authorization was created Grant *struct { Code string `json:"code"` // grant code received from OAuth web application authorization ExpiresIn int `json:"expires_in"` // seconds until OAuth grant expires ID string `json:"id"` // unique identifier of OAuth grant } `json:"grant"` // this authorization's grant ID string `json:"id"` // unique identifier of OAuth authorization RefreshToken *struct { ExpiresIn *int `json:"expires_in"` // seconds until OAuth token expires; may be `null` for tokens with // indefinite lifetime ID string `json:"id"` // unique identifier of OAuth token Token string `json:"token"` // contents of the token to be used for authorization } `json:"refresh_token"` // refresh token for this authorization Scope []string `json:"scope"` // The scope of access OAuth authorization allows UpdatedAt time.Time `json:"updated_at"` // when OAuth authorization was updated }
OAuth authorizations represent clients that a Heroku user has authorized to automate, customize or extend their usage of the platform. For more information please refer to the [Heroku OAuth documentation](https://devcenter.heroku.com/articles/oauth)
type OAuthAuthorizationCreateOpts ¶
type OAuthAuthorizationCreateOpts struct { Client *string `json:"client,omitempty"` // unique identifier of this OAuth client Description *string `json:"description,omitempty"` // human-friendly description of this OAuth authorization ExpiresIn *int `json:"expires_in,omitempty"` // seconds until OAuth token expires; may be `null` for tokens with // indefinite lifetime Scope []string `json:"scope"` // The scope of access OAuth authorization allows }
type OAuthClient ¶
type OAuthClient struct { CreatedAt time.Time `json:"created_at"` // when OAuth client was created ID string `json:"id"` // unique identifier of this OAuth client IgnoresDelinquent *bool `json:"ignores_delinquent"` // whether the client is still operable given a delinquent account Name string `json:"name"` // OAuth client name RedirectURI string `json:"redirect_uri"` // endpoint for redirection after authorization with OAuth client Secret string `json:"secret"` // secret used to obtain OAuth authorizations under this client UpdatedAt time.Time `json:"updated_at"` // when OAuth client was updated }
OAuth clients are applications that Heroku users can authorize to automate, customize or extend their usage of the platform. For more information please refer to the [Heroku OAuth documentation](https://devcenter.heroku.com/articles/oauth).
type OAuthClientCreateOpts ¶
type OAuthClientUpdateOpts ¶
type OAuthGrant ¶
type OAuthGrant struct{}
OAuth grants are used to obtain authorizations on behalf of a user. For more information please refer to the [Heroku OAuth documentation](https://devcenter.heroku.com/articles/oauth)
type OAuthToken ¶
type OAuthToken struct { AccessToken struct { ExpiresIn *int `json:"expires_in"` // seconds until OAuth token expires; may be `null` for tokens with // indefinite lifetime ID string `json:"id"` // unique identifier of OAuth token Token string `json:"token"` // contents of the token to be used for authorization } `json:"access_token"` // current access token Authorization struct { ID string `json:"id"` // unique identifier of OAuth authorization } `json:"authorization"` // authorization for this set of tokens Client *struct { Secret string `json:"secret"` // secret used to obtain OAuth authorizations under this client } `json:"client"` // OAuth client secret used to obtain token CreatedAt time.Time `json:"created_at"` // when OAuth token was created Grant struct { Code string `json:"code"` // grant code received from OAuth web application authorization Type string `json:"type"` // type of grant requested, one of `authorization_code` or } `json:"grant"` // grant used on the underlying authorization ID string `json:"id"` // unique identifier of OAuth token RefreshToken struct { ExpiresIn *int `json:"expires_in"` // seconds until OAuth token expires; may be `null` for tokens with // indefinite lifetime ID string `json:"id"` // unique identifier of OAuth token Token string `json:"token"` // contents of the token to be used for authorization } `json:"refresh_token"` // refresh token for this authorization Session struct { ID string `json:"id"` // unique identifier of OAuth token } `json:"session"` // OAuth session using this token UpdatedAt time.Time `json:"updated_at"` // when OAuth token was updated User struct { ID string `json:"id"` // unique identifier of an account } `json:"user"` // Reference to the user associated with this token }
OAuth tokens provide access for authorized clients to act on behalf of a Heroku user to automate, customize or extend their usage of the platform. For more information please refer to the [Heroku OAuth documentation](https://devcenter.heroku.com/articles/oauth)
type OAuthTokenCreateOpts ¶
type OAuthTokenCreateOpts struct { Client struct { Secret *string `json:"secret,omitempty"` // secret used to obtain OAuth authorizations under this client } `json:"client"` Grant struct { Code *string `json:"code,omitempty"` // grant code received from OAuth web application authorization Type *string `json:"type,omitempty"` // type of grant requested, one of `authorization_code` or } `json:"grant"` RefreshToken struct { Token *string `json:"token,omitempty"` // contents of the token to be used for authorization } `json:"refresh_token"` }
type Organization ¶
type Organization struct { CreditCardCollections bool `json:"credit_card_collections"` // whether charges incurred by the org are paid by credit card. Default bool `json:"default"` // whether to use this organization when none is specified Name string `json:"name"` // unique name of organization ProvisionedLicenses bool `json:"provisioned_licenses"` // whether the org is provisioned licenses by salesforce. Role string `json:"role"` // role in the organization }
Organizations allow you to manage access to a shared group of applications across your development team.
type OrganizationApp ¶
type OrganizationApp struct { ArchivedAt *time.Time `json:"archived_at"` // when app was archived BuildpackProvidedDescription *string `json:"buildpack_provided_description"` // description from buildpack of app CreatedAt time.Time `json:"created_at"` // when app was created GitURL string `json:"git_url"` // git repo URL of app ID string `json:"id"` // unique identifier of app Joined bool `json:"joined"` // is the current member a collaborator on this app. Locked bool `json:"locked"` // are other organization members forbidden from joining this app. Maintenance bool `json:"maintenance"` // maintenance status of app Name string `json:"name"` // unique name of app Organization *struct { Name string `json:"name"` // unique name of organization } `json:"organization"` // organization that owns this app Owner *struct { Email string `json:"email"` // unique email address of account ID string `json:"id"` // unique identifier of an account } `json:"owner"` // identity of app owner Region struct { ID string `json:"id"` // unique identifier of region Name string `json:"name"` // unique name of region } `json:"region"` // identity of app region ReleasedAt *time.Time `json:"released_at"` // when app was released RepoSize *int `json:"repo_size"` // git repo size in bytes of app SlugSize *int `json:"slug_size"` // slug size in bytes of app Stack struct { ID string `json:"id"` // unique identifier of stack Name string `json:"name"` // unique name of stack } `json:"stack"` // identity of app stack UpdatedAt time.Time `json:"updated_at"` // when app was updated WebURL string `json:"web_url"` // web URL of app }
An organization app encapsulates the organization specific functionality of Heroku apps.
type OrganizationAppCollaborator ¶
type OrganizationAppCollaborator struct { CreatedAt time.Time `json:"created_at"` // when collaborator was created ID string `json:"id"` // unique identifier of collaborator Role string `json:"role"` // role in the organization UpdatedAt time.Time `json:"updated_at"` // when collaborator was updated User struct { Email string `json:"email"` // unique email address of account ID string `json:"id"` // unique identifier of an account } `json:"user"` // identity of collaborated account }
An organization collaborator represents an account that has been given access to an organization app on Heroku.
type OrganizationAppCreateOpts ¶
type OrganizationAppCreateOpts struct { Locked *bool `json:"locked,omitempty"` // are other organization members forbidden from joining this app. Name *string `json:"name,omitempty"` // unique name of app Organization *string `json:"organization,omitempty"` // unique name of organization Personal *bool `json:"personal,omitempty"` // force creation of the app in the user account even if a default org // is set. Region *string `json:"region,omitempty"` // unique name of region Stack *string `json:"stack,omitempty"` // unique name of stack }
type OrganizationAppTransferToAccountOpts ¶
type OrganizationAppTransferToAccountOpts struct {
Owner string `json:"owner"` // unique email address of account
}
type OrganizationAppTransferToOrganizationOpts ¶
type OrganizationAppTransferToOrganizationOpts struct {
Owner string `json:"owner"` // unique name of organization
}
type OrganizationAppUpdateLockedOpts ¶
type OrganizationAppUpdateLockedOpts struct {
Locked bool `json:"locked"` // are other organization members forbidden from joining this app.
}
type OrganizationMember ¶
type OrganizationMember struct { CreatedAt time.Time `json:"created_at"` // when organization-member was created Email string `json:"email"` // email address of the organization member Role string `json:"role"` // role in the organization UpdatedAt time.Time `json:"updated_at"` // when organization-member was updated }
An organization member is an individual with access to an organization.
type OrganizationUpdateOpts ¶
type OrganizationUpdateOpts struct {
Default *bool `json:"default,omitempty"` // whether to use this organization when none is specified
}
type Plan ¶
type Plan struct { CreatedAt time.Time `json:"created_at"` // when plan was created Default bool `json:"default"` // whether this plan is the default for its addon service Description string `json:"description"` // description of plan ID string `json:"id"` // unique identifier of this plan Name string `json:"name"` // unique name of this plan Price struct { Cents int `json:"cents"` // price in cents per unit of plan Unit string `json:"unit"` // unit of price for plan } `json:"price"` // price State string `json:"state"` // release status for plan UpdatedAt time.Time `json:"updated_at"` // when plan was updated }
Plans represent different configurations of add-ons that may be added to apps. Endpoints under add-on services can be accessed without authentication.
type RateLimit ¶
type RateLimit struct {
Remaining int `json:"remaining"` // allowed requests remaining in current interval
}
Rate Limit represents the number of request tokens each account holds. Requests to this endpoint do not count towards the rate limit.
type Region ¶
type Region struct { CreatedAt time.Time `json:"created_at"` // when region was created Description string `json:"description"` // description of region ID string `json:"id"` // unique identifier of region Name string `json:"name"` // unique name of region UpdatedAt time.Time `json:"updated_at"` // when region was updated }
A region represents a geographic location in which your application may run.
type Release ¶
type Release struct { CreatedAt time.Time `json:"created_at"` // when release was created Description string `json:"description"` // description of changes in this release ID string `json:"id"` // unique identifier of release Slug *struct { ID string `json:"id"` // unique identifier of slug } `json:"slug"` // slug running in this release UpdatedAt time.Time `json:"updated_at"` // when release was updated User struct { Email string `json:"email"` // unique email address of account ID string `json:"id"` // unique identifier of an account } `json:"user"` // user that created the release Version int `json:"version"` // unique version assigned to the release }
A release represents a combination of code, config vars and add-ons for an app on Heroku.
type ReleaseCreateOpts ¶
type ReleaseRollbackOpts ¶
type ReleaseRollbackOpts struct {
Release string `json:"release"` // unique identifier of release
}
type SSLEndpoint ¶
type SSLEndpoint struct { CertificateChain string `json:"certificate_chain"` // raw contents of the public certificate chain (eg: .crt or .pem file) CName string `json:"cname"` // canonical name record, the address to point a domain at CreatedAt time.Time `json:"created_at"` // when endpoint was created ID string `json:"id"` // unique identifier of this SSL endpoint Name string `json:"name"` // unique name for SSL endpoint UpdatedAt time.Time `json:"updated_at"` // when endpoint was updated }
[SSL Endpoint](https://devcenter.heroku.com/articles/ssl-endpoint) is a public address serving custom SSL cert for HTTPS traffic to a Heroku app. Note that an app must have the `ssl:endpoint` addon installed before it can provision an SSL Endpoint using these APIs.
type SSLEndpointCreateOpts ¶
type SSLEndpointCreateOpts struct { CertificateChain string `json:"certificate_chain"` // raw contents of the public certificate chain (eg: .crt or .pem file) Preprocess *bool `json:"preprocess,omitempty"` // allow Heroku to modify an uploaded public certificate chain if deemed // advantageous by adding missing intermediaries, stripping unnecessary // ones, etc. PrivateKey string `json:"private_key"` // contents of the private key (eg .key file) }
type SSLEndpointUpdateOpts ¶
type SSLEndpointUpdateOpts struct { CertificateChain *string `json:"certificate_chain,omitempty"` // raw contents of the public certificate chain (eg: .crt or .pem file) Preprocess *bool `json:"preprocess,omitempty"` // allow Heroku to modify an uploaded public certificate chain if deemed // advantageous by adding missing intermediaries, stripping unnecessary // ones, etc. PrivateKey *string `json:"private_key,omitempty"` // contents of the private key (eg .key file) Rollback *bool `json:"rollback,omitempty"` // indicates that a rollback should be performed }
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service represents your API.
func NewService ¶
NewService creates a Service using the given, if none is provided it uses http.DefaultClient.
func (*Service) AccountChangeEmail ¶
func (s *Service) AccountChangeEmail(o struct { Email string `json:"email"` // unique email address of account Password string `json:"password"` // current password on the account }) (*Account, error)
Change Email for account.
func (*Service) AccountChangePassword ¶
func (s *Service) AccountChangePassword(o struct { NewPassword string `json:"new_password"` // the new password for the account when changing the password Password string `json:"password"` // current password on the account }) (*Account, error)
Change Password for account.
func (*Service) AccountFeatureInfo ¶
func (s *Service) AccountFeatureInfo(accountFeatureIdentity string) (*AccountFeature, error)
Info for an existing account feature.
func (*Service) AccountFeatureList ¶
func (s *Service) AccountFeatureList(lr *ListRange) ([]*AccountFeature, error)
List existing account features.
func (*Service) AccountFeatureUpdate ¶
func (s *Service) AccountFeatureUpdate(accountFeatureIdentity string, o struct { Enabled bool `json:"enabled"` // whether or not account feature has been enabled }) (*AccountFeature, error)
Update an existing account feature.
func (*Service) AccountUpdate ¶
func (s *Service) AccountUpdate(o struct { AllowTracking *bool `json:"allow_tracking,omitempty"` // whether to allow third party web activity tracking Beta *bool `json:"beta,omitempty"` // whether allowed to utilize beta Heroku features Name *string `json:"name,omitempty"` // full name of the account owner Password string `json:"password"` // current password on the account }) (*Account, error)
Update account.
func (*Service) AddonCreate ¶
func (s *Service) AddonCreate(appIdentity string, o struct { Config *map[string]string `json:"config,omitempty"` // custom add-on provisioning options Plan string `json:"plan"` // unique identifier of this plan }) (*Addon, error)
Create a new add-on.
func (*Service) AddonDelete ¶
Delete an existing add-on.
func (*Service) AddonServiceInfo ¶
func (s *Service) AddonServiceInfo(addonServiceIdentity string) (*AddonService, error)
Info for existing addon-service.
func (*Service) AddonServiceList ¶
func (s *Service) AddonServiceList(lr *ListRange) ([]*AddonService, error)
List existing addon-services.
func (*Service) AddonUpdate ¶
func (s *Service) AddonUpdate(appIdentity string, addonIdentity string, o struct { Plan string `json:"plan"` // unique identifier of this plan }) (*Addon, error)
Change add-on plan. Some add-ons may not support changing plans. In that case, an error will be returned.
func (*Service) AppCreate ¶
func (s *Service) AppCreate(o struct { Name *string `json:"name,omitempty"` // unique name of app Region *string `json:"region,omitempty"` // unique identifier of region Stack *string `json:"stack,omitempty"` // unique name of stack }) (*App, error)
Create a new app.
func (*Service) AppFeatureInfo ¶
func (s *Service) AppFeatureInfo(appIdentity string, appFeatureIdentity string) (*AppFeature, error)
Info for an existing app feature.
func (*Service) AppFeatureList ¶
func (s *Service) AppFeatureList(appIdentity string, lr *ListRange) ([]*AppFeature, error)
List existing app features.
func (*Service) AppFeatureUpdate ¶
func (s *Service) AppFeatureUpdate(appIdentity string, appFeatureIdentity string, o struct { Enabled bool `json:"enabled"` // whether or not app feature has been enabled }) (*AppFeature, error)
Update an existing app feature.
func (*Service) AppSetupCreate ¶
func (s *Service) AppSetupCreate(o struct { App *struct { Locked *bool `json:"locked,omitempty"` // are other organization members forbidden from joining this app. Name *string `json:"name,omitempty"` // unique name of app Organization *string `json:"organization,omitempty"` // unique name of organization Personal *bool `json:"personal,omitempty"` // force creation of the app in the user account even if a default org // is set. Region *string `json:"region,omitempty"` // unique name of region Stack *string `json:"stack,omitempty"` // unique name of stack } `json:"app,omitempty"` // optional parameters for created app Overrides *struct { Env *map[string]string `json:"env,omitempty"` // overrides of the env specified in the app.json manifest file } `json:"overrides,omitempty"` // overrides of keys in the app.json manifest file SourceBlob struct { URL *string `json:"url,omitempty"` // URL of gzipped tarball of source code containing app.json manifest } `json:"source_blob"` // gzipped tarball of source code containing app.json manifest file }) (*AppSetup, error)
Create a new app setup from a gzipped tar archive containing an app.json manifest file.
func (*Service) AppSetupInfo ¶
Get the status of an app setup.
func (*Service) AppTransferCreate ¶
func (s *Service) AppTransferCreate(o struct { App string `json:"app"` // unique identifier of app Recipient string `json:"recipient"` // unique email address of account }) (*AppTransfer, error)
Create a new app transfer.
func (*Service) AppTransferDelete ¶
Delete an existing app transfer
func (*Service) AppTransferInfo ¶
func (s *Service) AppTransferInfo(appTransferIdentity string) (*AppTransfer, error)
Info for existing app transfer.
func (*Service) AppTransferList ¶
func (s *Service) AppTransferList(lr *ListRange) ([]*AppTransfer, error)
List existing apps transfers.
func (*Service) AppTransferUpdate ¶
func (s *Service) AppTransferUpdate(appTransferIdentity string, o struct { State string `json:"state"` // the current state of an app transfer }) (*AppTransfer, error)
Update an existing app transfer.
func (*Service) AppUpdate ¶
func (s *Service) AppUpdate(appIdentity string, o struct { Maintenance *bool `json:"maintenance,omitempty"` // maintenance status of app Name *string `json:"name,omitempty"` // unique name of app }) (*App, error)
Update an existing app.
func (*Service) BuildCreate ¶
func (s *Service) BuildCreate(appIdentity string, o struct { SourceBlob struct { URL *string `json:"url,omitempty"` // URL where gzipped tar archive of source code for build was // downloaded. Version *string `json:"version,omitempty"` // Version of the gzipped tarball. } `json:"source_blob"` // location of gzipped tarball of source code used to create build }) (*Build, error)
Create a new build.
func (*Service) BuildResultInfo ¶
func (s *Service) BuildResultInfo(appIdentity string, buildIdentity string) (*BuildResult, error)
Info for existing result.
func (*Service) CollaboratorCreate ¶
func (s *Service) CollaboratorCreate(appIdentity string, o struct { Silent *bool `json:"silent,omitempty"` // whether to suppress email invitation when creating collaborator User string `json:"user"` // unique email address of account }) (*Collaborator, error)
Create a new collaborator.
func (*Service) CollaboratorDelete ¶
Delete an existing collaborator.
func (*Service) CollaboratorInfo ¶
func (s *Service) CollaboratorInfo(appIdentity string, collaboratorIdentity string) (*Collaborator, error)
Info for existing collaborator.
func (*Service) CollaboratorList ¶
func (s *Service) CollaboratorList(appIdentity string, lr *ListRange) ([]*Collaborator, error)
List existing collaborators.
func (*Service) ConfigVarInfo ¶
Get config-vars for app.
func (*Service) ConfigVarUpdate ¶
func (s *Service) ConfigVarUpdate(appIdentity string, o map[string]*string) (map[string]string, error)
Update config-vars for app. You can update existing config-vars by setting them again, and remove by setting it to `NULL`.
func (*Service) CreditInfo ¶
Info for existing credit.
func (*Service) CreditList ¶
List existing credits.
func (*Service) DomainCreate ¶
func (s *Service) DomainCreate(appIdentity string, o struct { Hostname string `json:"hostname"` // full hostname }) (*Domain, error)
Create a new domain.
func (*Service) DomainDelete ¶
Delete an existing domain
func (*Service) DomainInfo ¶
Info for existing domain.
func (*Service) DomainList ¶
List existing domains.
func (*Service) DynoCreate ¶
func (s *Service) DynoCreate(appIdentity string, o struct { Attach *bool `json:"attach,omitempty"` // whether to stream output or not Command string `json:"command"` // command used to start this process Env *map[string]string `json:"env,omitempty"` // custom environment to add to the dyno config vars Size *string `json:"size,omitempty"` // dyno size (default: "1X") }) (*Dyno, error)
Create a new dyno.
func (*Service) DynoRestart ¶
Restart dyno.
func (*Service) DynoRestartAll ¶
Restart all dynos
func (*Service) FormationBatchUpdate ¶
func (s *Service) FormationBatchUpdate(appIdentity string, o struct { Updates []struct { Process string `json:"process"` // unique identifier of this process type Quantity *int `json:"quantity,omitempty"` // number of processes to maintain Size *string `json:"size,omitempty"` // dyno size (default: "1X") } `json:"updates"` // Array with formation updates. Each element must have "process", the }) (*Formation, error)
Batch update process types
func (*Service) FormationInfo ¶
Info for a process type
func (*Service) FormationList ¶
List process type formation
func (*Service) FormationUpdate ¶
func (s *Service) FormationUpdate(appIdentity string, formationIdentity string, o struct { Quantity *int `json:"quantity,omitempty"` // number of processes to maintain Size *string `json:"size,omitempty"` // dyno size (default: "1X") }) (*Formation, error)
Update process type
func (*Service) KeyCreate ¶
func (s *Service) KeyCreate(o struct { PublicKey string `json:"public_key"` // full public_key as uploaded }) (*Key, error)
Create a new key.
func (*Service) LogDrainCreate ¶
func (s *Service) LogDrainCreate(appIdentity string, o struct { URL string `json:"url"` // url associated with the log drain }) (*LogDrain, error)
Create a new log drain.
func (*Service) LogDrainDelete ¶
Delete an existing log drain. Log drains added by add-ons can only be removed by removing the add-on.
func (*Service) LogDrainInfo ¶
Info for existing log drain.
func (*Service) LogDrainList ¶
List existing log drains.
func (*Service) LogSessionCreate ¶
func (s *Service) LogSessionCreate(appIdentity string, o struct { Dyno *string `json:"dyno,omitempty"` // dyno to limit results to Lines *int `json:"lines,omitempty"` // number of log lines to stream at once Source *string `json:"source,omitempty"` // log source to limit results to Tail *bool `json:"tail,omitempty"` // whether to stream ongoing logs }) (*LogSession, error)
Create a new log session.
func (*Service) NewRequest ¶
NewRequest generates an HTTP request, but does not perform the request.
func (*Service) OAuthAuthorizationCreate ¶
func (s *Service) OAuthAuthorizationCreate(o struct { Client *string `json:"client,omitempty"` // unique identifier of this OAuth client Description *string `json:"description,omitempty"` // human-friendly description of this OAuth authorization ExpiresIn *int `json:"expires_in,omitempty"` // seconds until OAuth token expires; may be `null` for tokens with // indefinite lifetime Scope []string `json:"scope"` // The scope of access OAuth authorization allows }) (*OAuthAuthorization, error)
Create a new OAuth authorization.
func (*Service) OAuthAuthorizationDelete ¶
Delete OAuth authorization.
func (*Service) OAuthAuthorizationInfo ¶
func (s *Service) OAuthAuthorizationInfo(oauthAuthorizationIdentity string) (*OAuthAuthorization, error)
Info for an OAuth authorization.
func (*Service) OAuthAuthorizationList ¶
func (s *Service) OAuthAuthorizationList(lr *ListRange) ([]*OAuthAuthorization, error)
List OAuth authorizations.
func (*Service) OAuthClientCreate ¶
func (s *Service) OAuthClientCreate(o struct { Name string `json:"name"` // OAuth client name RedirectURI string `json:"redirect_uri"` // endpoint for redirection after authorization with OAuth client }) (*OAuthClient, error)
Create a new OAuth client.
func (*Service) OAuthClientDelete ¶
Delete OAuth client.
func (*Service) OAuthClientInfo ¶
func (s *Service) OAuthClientInfo(oauthClientIdentity string) (*OAuthClient, error)
Info for an OAuth client
func (*Service) OAuthClientList ¶
func (s *Service) OAuthClientList(lr *ListRange) ([]*OAuthClient, error)
List OAuth clients
func (*Service) OAuthClientUpdate ¶
func (s *Service) OAuthClientUpdate(oauthClientIdentity string, o struct { Name *string `json:"name,omitempty"` // OAuth client name RedirectURI *string `json:"redirect_uri,omitempty"` // endpoint for redirection after authorization with OAuth client }) (*OAuthClient, error)
Update OAuth client
func (*Service) OAuthTokenCreate ¶
func (s *Service) OAuthTokenCreate(o struct { Client struct { Secret *string `json:"secret,omitempty"` // secret used to obtain OAuth authorizations under this client } `json:"client"` Grant struct { Code *string `json:"code,omitempty"` // grant code received from OAuth web application authorization Type *string `json:"type,omitempty"` // type of grant requested, one of `authorization_code` or } `json:"grant"` RefreshToken struct { Token *string `json:"token,omitempty"` // contents of the token to be used for authorization } `json:"refresh_token"` }) (*OAuthToken, error)
Create a new OAuth token.
func (*Service) OrganizationAppCollaboratorCreate ¶
func (s *Service) OrganizationAppCollaboratorCreate(appIdentity string, o struct { Silent *bool `json:"silent,omitempty"` // whether to suppress email invitation when creating collaborator User string `json:"user"` // unique email address of account }) (*OrganizationAppCollaborator, error)
Create a new collaborator on an organization app. Use this endpoint instead of the `/apps/{app_id_or_name}/collaborator` endpoint when you want the collaborator to be granted [privileges] (https://devcenter.heroku.com/articles/org-users-access#roles) according to their role in the organization.
func (*Service) OrganizationAppCollaboratorDelete ¶
func (s *Service) OrganizationAppCollaboratorDelete(organizationAppIdentity string, organizationAppCollaboratorIdentity string) error
Delete an existing collaborator from an organization app.
func (*Service) OrganizationAppCollaboratorInfo ¶
func (s *Service) OrganizationAppCollaboratorInfo(organizationAppIdentity string, organizationAppCollaboratorIdentity string) (*OrganizationAppCollaborator, error)
Info for a collaborator on an organization app.
func (*Service) OrganizationAppCollaboratorList ¶
func (s *Service) OrganizationAppCollaboratorList(organizationAppIdentity string, lr *ListRange) ([]*OrganizationAppCollaborator, error)
List collaborators on an organization app.
func (*Service) OrganizationAppCreate ¶
func (s *Service) OrganizationAppCreate(o struct { Locked *bool `json:"locked,omitempty"` // are other organization members forbidden from joining this app. Name *string `json:"name,omitempty"` // unique name of app Organization *string `json:"organization,omitempty"` // unique name of organization Personal *bool `json:"personal,omitempty"` // force creation of the app in the user account even if a default org // is set. Region *string `json:"region,omitempty"` // unique name of region Stack *string `json:"stack,omitempty"` // unique name of stack }) (*OrganizationApp, error)
Create a new app in the specified organization, in the default organization if unspecified, or in personal account, if default organization is not set.
func (*Service) OrganizationAppInfo ¶
func (s *Service) OrganizationAppInfo(organizationAppIdentity string) (*OrganizationApp, error)
Info for an organization app.
func (*Service) OrganizationAppList ¶
func (s *Service) OrganizationAppList(lr *ListRange) ([]*OrganizationApp, error)
List apps in the default organization, or in personal account, if default organization is not set.
func (*Service) OrganizationAppListForOrganization ¶
func (s *Service) OrganizationAppListForOrganization(organizationIdentity string, lr *ListRange) ([]*OrganizationApp, error)
List organization apps.
func (*Service) OrganizationAppTransferToAccount ¶
func (s *Service) OrganizationAppTransferToAccount(organizationAppIdentity string, o struct { Owner string `json:"owner"` // unique email address of account }) (*OrganizationApp, error)
Transfer an existing organization app to another Heroku account.
func (*Service) OrganizationAppTransferToOrganization ¶
func (s *Service) OrganizationAppTransferToOrganization(organizationAppIdentity string, o struct { Owner string `json:"owner"` // unique name of organization }) (*OrganizationApp, error)
Transfer an existing organization app to another organization.
func (*Service) OrganizationAppUpdateLocked ¶
func (s *Service) OrganizationAppUpdateLocked(organizationAppIdentity string, o struct { Locked bool `json:"locked"` // are other organization members forbidden from joining this app. }) (*OrganizationApp, error)
Lock or unlock an organization app.
func (*Service) OrganizationList ¶
func (s *Service) OrganizationList(lr *ListRange) ([]*Organization, error)
List organizations in which you are a member.
func (*Service) OrganizationMemberCreateOrUpdate ¶
func (s *Service) OrganizationMemberCreateOrUpdate(organizationIdentity string, o struct { Email string `json:"email"` // email address of the organization member Role string `json:"role"` // role in the organization }) (*OrganizationMember, error)
Create a new organization member, or update their role.
func (*Service) OrganizationMemberDelete ¶
func (s *Service) OrganizationMemberDelete(organizationIdentity string, organizationMemberIdentity string) error
Remove a member from the organization.
func (*Service) OrganizationMemberList ¶
func (s *Service) OrganizationMemberList(organizationIdentity string, lr *ListRange) ([]*OrganizationMember, error)
List members of the organization.
func (*Service) OrganizationUpdate ¶
func (s *Service) OrganizationUpdate(organizationIdentity string, o struct { Default *bool `json:"default,omitempty"` // whether to use this organization when none is specified }) (*Organization, error)
Set or unset the organization as your default organization.
func (*Service) RateLimitInfo ¶
Info for rate limits.
func (*Service) RegionInfo ¶
Info for existing region.
func (*Service) RegionList ¶
List existing regions.
func (*Service) ReleaseCreate ¶
func (s *Service) ReleaseCreate(appIdentity string, o struct { Description *string `json:"description,omitempty"` // description of changes in this release Slug string `json:"slug"` // unique identifier of slug }) (*Release, error)
Create new release. The API cannot be used to create releases on Bamboo apps.
func (*Service) ReleaseInfo ¶
Info for existing release.
func (*Service) ReleaseList ¶
List existing releases.
func (*Service) ReleaseRollback ¶
func (s *Service) ReleaseRollback(appIdentity string, o struct { Release string `json:"release"` // unique identifier of release }) (*Release, error)
Rollback to an existing release.
func (*Service) SSLEndpointCreate ¶
func (s *Service) SSLEndpointCreate(appIdentity string, o struct { CertificateChain string `json:"certificate_chain"` // raw contents of the public certificate chain (eg: .crt or .pem file) Preprocess *bool `json:"preprocess,omitempty"` // allow Heroku to modify an uploaded public certificate chain if deemed // advantageous by adding missing intermediaries, stripping unnecessary // ones, etc. PrivateKey string `json:"private_key"` // contents of the private key (eg .key file) }) (*SSLEndpoint, error)
Create a new SSL endpoint.
func (*Service) SSLEndpointDelete ¶
Delete existing SSL endpoint.
func (*Service) SSLEndpointInfo ¶
func (s *Service) SSLEndpointInfo(appIdentity string, sslEndpointIdentity string) (*SSLEndpoint, error)
Info for existing SSL endpoint.
func (*Service) SSLEndpointList ¶
func (s *Service) SSLEndpointList(appIdentity string, lr *ListRange) ([]*SSLEndpoint, error)
List existing SSL endpoints.
func (*Service) SSLEndpointUpdate ¶
func (s *Service) SSLEndpointUpdate(appIdentity string, sslEndpointIdentity string, o struct { CertificateChain *string `json:"certificate_chain,omitempty"` // raw contents of the public certificate chain (eg: .crt or .pem file) Preprocess *bool `json:"preprocess,omitempty"` // allow Heroku to modify an uploaded public certificate chain if deemed // advantageous by adding missing intermediaries, stripping unnecessary // ones, etc. PrivateKey *string `json:"private_key,omitempty"` // contents of the private key (eg .key file) Rollback *bool `json:"rollback,omitempty"` // indicates that a rollback should be performed }) (*SSLEndpoint, error)
Update an existing SSL endpoint.
func (*Service) SlugCreate ¶
func (s *Service) SlugCreate(appIdentity string, o struct { BuildpackProvidedDescription *string `json:"buildpack_provided_description,omitempty"` // description from buildpack of slug Commit *string `json:"commit,omitempty"` // identification of the code with your version control system (eg: SHA // of the git HEAD) ProcessTypes map[string]string `json:"process_types"` // hash mapping process type names to their respective command }) (*Slug, error)
Create a new slug. For more information please refer to [Deploying Slugs using the Platform API](https://devcenter.heroku.com/articles/platform-api-deploying-slug s?preview=1).
type Slug ¶
type Slug struct { Blob struct { Method string `json:"method"` // method to be used to interact with the slug blob URL string `json:"url"` // URL to interact with the slug blob } `json:"blob"` // pointer to the url where clients can fetch or store the actual // release binary BuildpackProvidedDescription *string `json:"buildpack_provided_description"` // description from buildpack of slug Commit *string `json:"commit"` // identification of the code with your version control system (eg: SHA // of the git HEAD) CreatedAt time.Time `json:"created_at"` // when slug was created ID string `json:"id"` // unique identifier of slug ProcessTypes map[string]string `json:"process_types"` // hash mapping process type names to their respective command Size *int `json:"size"` // size of slug, in bytes UpdatedAt time.Time `json:"updated_at"` // when slug was updated }
A slug is a snapshot of your application code that is ready to run on the platform.
type SlugCreateOpts ¶
type SlugCreateOpts struct { BuildpackProvidedDescription *string `json:"buildpack_provided_description,omitempty"` // description from buildpack of slug Commit *string `json:"commit,omitempty"` // identification of the code with your version control system (eg: SHA // of the git HEAD) ProcessTypes map[string]string `json:"process_types"` // hash mapping process type names to their respective command }
type Stack ¶
type Stack struct { CreatedAt time.Time `json:"created_at"` // when stack was introduced ID string `json:"id"` // unique identifier of stack Name string `json:"name"` // unique name of stack State string `json:"state"` // availability of this stack: beta, deprecated or public UpdatedAt time.Time `json:"updated_at"` // when stack was last modified }
Stacks are the different application execution environments available in the Heroku platform.
type Transport ¶
type Transport struct { // Username is the HTTP basic auth username for API calls made by this Client. Username string // Password is the HTTP basic auth password for API calls made by this Client. Password string // UserAgent to be provided in API requests. Set to DefaultUserAgent if not // specified. UserAgent string // Debug mode can be used to dump the full request and response to stdout. Debug bool // AdditionalHeaders are extra headers to add to each HTTP request sent by // this Client. AdditionalHeaders http.Header // Transport is the HTTP transport to use when making requests. // It will default to http.DefaultTransport if nil. Transport http.RoundTripper }
func (*Transport) CancelRequest ¶
Forward CancelRequest to underlying Transport