v1

package
v3.0.0-rc.2 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func String

func String(v string) *string

Types

type AccessToken

type AccessToken struct {
	AccessToken  *string `json:"access_token,omitempty"`
	ExpiresIn    *int    `json:"expires_in,omitempty"`
	Scope        *string `json:"scope,omitempty"`
	TokenType    *string `json:"token_type,omitempty"`
	RefreshToken *string `json:"refresh_token,omitempty"`
}

func (AccessToken) String

func (r AccessToken) String() string

type AccessTokenOptions

type AccessTokenOptions struct {
	// The grant type used to authenticate the request. In this case, the only value supported is "client_credentials" which is also the default value if this parameter is not specified.
	GrantType *string `url:"grant_type,omitempty"` // [Optional, default: "client_credentials"]
	// The user name for which this token is created. If the user does not exist, a transient user is created. Non-admin users can only create tokens for themselves so they must specify their own username.
	// If the user does not exist, the member-of-groups scope token must be provided (e.g. member-of-groups: g1, g2, g3...)
	Username *string `url:"username,omitempty"`
	// The scope to assign to the token provided as a space-separated list of scope tokens. Currently there are three possible scope tokens:
	//     - "api:*" - indicates that the token grants access to REST API calls. This is always granted by default whether specified in the call or not.
	//     - member-of-groups:[<group-name>] - indicates the groups that the token is associated with (e.g. member-of-groups: g1, g2, g3...). The token grants access according to the permission targets specified for the groups listed.
	//       Specify "*" for group-name to indicate that the token should provide the same access privileges that are given to the group of which the logged in user is a member.
	//       A non-admin user can only provide a scope that is a subset of the groups to which he belongs
	//     - "jfrt@<instance-id>:admin" - provides admin privileges on the specified Artifactory instance. This is only available for administrators.
	// If omitted and the username specified exists, the token is granted the scope of that user.
	Scope *string `url:"scope,omitempty"` // [Optional if the user specified in username exists]
	// The time in seconds for which the token will be valid. To specify a token that never expires, set to zero. Non-admin can only set a value that is equal to or less than the default 3600.
	ExpiresIn *int `url:"expires_in,omitempty"` // [Optional, default: 3600]
	// If true, this token is refreshable and the refresh token can be used to replace it with a new token once it expires.
	Refreshable *string `url:"refreshable,omitempty"` // [Optional, default: false]
	// A space-separate list of the other Artifactory instances or services that should accept this token identified by their Artifactory Service IDs as obtained from the Get Service ID endpoint.
	// In case you want the token to be accepted by all Artifactory instances you may use the following audience parameter "audience=jfrt@*".
	Audience *string `url:"audience,omitempty"` // [Optional, default: Only the Service ID of the Artifactory instance that created the token]
}

type AccessTokenRefreshOptions

type AccessTokenRefreshOptions struct {
	// Should be set to refresh_token.
	GrantType *string `url:"grant_type,omitempty"`
	// The refresh token of the access token that needs to be refreshed.
	RefreshToken *string `url:"refresh_token,omitempty"`
	// The access token to refresh.
	AccessToken *string `url:"access_token,omitempty"`
	// The user name for which this token is created. If the user does not exist, a transient user is created. Non-admin users can only create tokens for themselves so they must specify their own username.
	// If the user does not exist, the member-of-groups scope token must be provided (e.g. member-of-groups: g1, g2, g3...)
	// Note: access_token and username are mutually exclusive, so only one of these parameters should be specified.
	Username *string `url:"username,omitempty"`
	// The scope to assign to the token provided as a space-separated list of scope tokens. Currently there are three possible scope tokens:
	//     - "api:*" - indicates that the token grants access to REST API calls. This is always granted by default whether specified in the call or not.
	//     - member-of-groups:[<group-name>] - indicates the groups that the token is associated with (e.g. member-of-groups: g1, g2, g3...). The token grants access according to the permission targets specified for the groups listed.
	//       Specify "*" for group-name to indicate that the token should provide the same access privileges that are given to the group of which the logged in user is a member.
	//       A non-admin user can only provide a scope that is a subset of the groups to which he belongs
	//     - "jfrt@<instance-id>:admin" - provides admin privileges on the specified Artifactory instance. This is only available for administrators.
	// If omitted and the username specified exists, the token is granted the scope of that user.
	Scope *string `url:"scope,omitempty"`
	// The time in seconds for which the token will be valid. To specify a token that never expires, set to zero. Non-admin can only set a value that is equal to or less than the default 3600.
	ExpiresIn *int `url:"expires_in,omitempty"`
	// If true, this token is refreshable and the refresh token can be used to replace it with a new token once it expires.
	Refreshable *string `url:"refreshable,omitempty"`
	// A space-separate list of the other Artifactory instances or services that should accept this token identified by their Artifactory Service IDs as obtained from the Get Service ID endpoint.
	// In case you want the token to be accepted by all Artifactory instances you may use the following audience parameter "audience=jfrt@*".
	Audience *string `url:"audience,omitempty"`
}

type AccessTokenRevokeOptions

type AccessTokenRevokeOptions struct {
	Token string `url:"token,omitempty"`
}

type ApiKey

type ApiKey struct {
	ApiKey *string `json:"apiKey,omitempty"`
}

type ArtifactService

type ArtifactService Service

ArtifactService exposes the Artifact API endpoints from Artifactory

func (*ArtifactService) GetRepositoryReplicationConfig

func (s *ArtifactService) GetRepositoryReplicationConfig(ctx context.Context, repoKey string) (*[]SingleReplicationConfig, *resty.Response, error)

Returns the replication configuration for the given repository key, if found. Supported by local and remote repositories. Note: The 'enableEventReplication' parameter refers to both push and pull replication. Notes: Requires Artifactory Pro Security: Requires a privileged user

func (*ArtifactService) SetRepositoryReplicationConfig

func (s *ArtifactService) SetRepositoryReplicationConfig(ctx context.Context, repoKey string, config *ReplicationConfig) (*resty.Response, error)

Creates or replaces a local multi-push replication configuration. Supported by local repositories. Notes: Requires an enterprise license Security: Requires a privileged user

func (*ArtifactService) SetSingleRepositoryReplicationConfig

func (s *ArtifactService) SetSingleRepositoryReplicationConfig(ctx context.Context, repoKey string, config *SingleReplicationConfig) (*resty.Response, error)

Description: Add or replace replication configuration for given repository key. Supported by local and remote repositories. Accepts the JSON payload returned from Get Repository Replication Configuration for a single and an array of configurations. If the payload is an array of replication configurations, then values for cronExp and enableEventReplication in the first element in the array will determine the corresponding values when setting the repository replication configuration. Notes: Requires Artifactory Pro Security: Requires an admin user

type CertificateDetails

type CertificateDetails struct {
	CertificateAlias *string `json:"certificateAlias,omitempty"`
	IssuedTo         *string `json:"issuedTo,omitempty"`
	IssuedBy         *string `json:"issuedby,omitempty"`
	IssuedOn         *string `json:"issuedOn,omitempty"`
	ValidUntil       *string `json:"validUntil,omitempty"`
	FingerPrint      *string `json:"fingerPrint,omitempty"`
}

func (CertificateDetails) String

func (r CertificateDetails) String() string

type ContentSynchronisation

type ContentSynchronisation struct {
	Enabled    *bool       `json:"enabled,omitempty"`
	Statistics *Statistics `json:"statistics,omitempty"`
	Properties *Properties `json:"properties,omitempty"`
	Source     *Source     `json:"source,omitempty"`
}

type Group

type Group struct {
	Name            *string `json:"name,omitempty"`            // Optional element in create/replace queries
	Description     *string `json:"description,omitempty"`     // Optional element in create/replace queries
	AutoJoin        *bool   `json:"autoJoin,omitempty"`        // Optional element in create/replace queries; default: false (must be false if adminPrivileges is true)
	AdminPrivileges *bool   `json:"adminPrivileges,omitempty"` // Optional element in create/replace queries; default: false
	Realm           *string `json:"realm,omitempty"`           // Optional element in create/replace queries
	RealmAttributes *string `json:"realmAttributes,omitempty"` // Optional element in create/replace queries
}

application/vnd.org.jfrog.artifactory.security.Group+json

func (Group) String

func (r Group) String() string

type GroupDetails

type GroupDetails struct {
	Name *string `json:"name,omitempty"`
	Uri  *string `json:"uri,omitempty"`
}

application/vnd.org.jfrog.artifactory.security.Groups+json

func (GroupDetails) String

func (r GroupDetails) String() string

type HALicense

type HALicense struct {
	Type         *string `json:"type,omitempty"`
	ValidThrough *string `json:"validThrough,omitempty"` // validity date formatted MMM DD, YYYY
	LicensedTo   *string `json:"licensedTo,omitempty"`
	LicenseHash  *string `json:"licenseHash,omitempty"`
	NodeId       *string `json:"nodeId,omitempty"`  // Node ID of the node activated with this license | Not in use
	NodeUrl      *string `json:"nodeUrl,omitempty"` // URL of the node activated with this license | Not in use
	Expired      *bool   `json:"expired,omitempty"`
}

type HALicenseHashes

type HALicenseHashes struct {
	LicenseHash *[]string `url:"licenseHash,omitempty"`
}

type HALicenses

type HALicenses struct {
	Licenses *[]HALicense `json:"licenses,omitempty"`
}

func (HALicenses) String

func (r HALicenses) String() string

type ItemPermissions

type ItemPermissions struct {
	Uri        *string     `json:"uri,omitempty"`
	Principals *Principals `json:"principals,omitempty"`
}

Permissions are returned according to the following conventions: m=admin; d=delete; w=deploy; n=annotate; r=read

func (ItemPermissions) String

func (r ItemPermissions) String() string

type LicenseDetails

type LicenseDetails struct {
	Type         *string `json:"type,omitempty"`
	ValidThrough *string `json:"validThrough,omitempty"`
	LicensedTo   *string `json:"licensedTo,omitempty"`
}

func (LicenseDetails) String

func (r LicenseDetails) String() string

type LicenseKey

type LicenseKey struct {
	LicenseKey *string `json:"licenseKey,omitempty"`
}

type LocalRepository

type LocalRepository struct {
	Key                          *string   `json:"key,omitempty"`
	RClass                       *string   `json:"rclass,omitempty"` // Mandatory element in create/replace queries (optional in "update" queries)
	PackageType                  *string   `json:"packageType,omitempty"`
	Description                  *string   `json:"description,omitempty"`
	Notes                        *string   `json:"notes,omitempty"`
	IncludesPattern              *string   `json:"includesPattern,omitempty"`
	ExcludesPattern              *string   `json:"excludesPattern,omitempty"`
	ArchiveBrowsingEnabled       *bool     `json:"archiveBrowsingEnabled,omitempty"`
	BlackedOut                   *bool     `json:"blackedOut,omitempty"`
	BlockXrayUnscannedArtifacts  *bool     `json:"blockXrayUnscannedArtifacts,omitempty"`
	CalculateYumMetadata         *bool     `json:"calculateYumMetadata,omitempty"`
	ChecksumPolicyType           *string   `json:"checksumPolicyType,omitempty"`
	DebianTrivialLayout          *bool     `json:"debianTrivialLayout,omitempty"`
	DockerApiVersion             *string   `json:"dockerApiVersion,omitempty"`
	EnableBowerSupport           *bool     `json:"enableBowerSupport,omitempty"`
	EnableCocoaPodsSupport       *bool     `json:"enableCocoaPodsSupport,omitempty"`
	EnableComposerSupport        *bool     `json:"enableComposerSupport,omitempty"`
	EnableConanSupport           *bool     `json:"enableConanSupport,omitempty"`
	EnableDebianSupport          *bool     `json:"enableDebianSupport,omitempty"`
	EnableDistRepoSupport        *bool     `json:"enableDistRepoSupport,omitempty"`
	EnableDockerSupport          *bool     `json:"enableDockerSupport,omitempty"`
	EnableFileListsIndexing      *bool     `json:"enableFileListsIndexing,omitempty"`
	EnableGemsSupport            *bool     `json:"enableGemsSupport,omitempty"`
	EnableGitLfsSupport          *bool     `json:"enableGitLfsSupport,omitempty"`
	EnableNpmSupport             *bool     `json:"enableNpmSupport,omitempty"`
	EnableNuGetSupport           *bool     `json:"enableNuGetSupport,omitempty"`
	EnablePuppetSupport          *bool     `json:"enablePuppetSupport,omitempty"`
	EnablePypiSupport            *bool     `json:"enablePypiSupport,omitempty"`
	EnableVagrantSupport         *bool     `json:"enableVagrantSupport,omitempty"`
	EnabledChefSupport           *bool     `json:"enabledChefSupport,omitempty"`
	ForceNugetAuthentication     *bool     `json:"forceNugetAuthentication,omitempty"`
	HandleReleases               *bool     `json:"handleReleases,omitempty"`
	HandleSnapshots              *bool     `json:"handleSnapshots,omitempty"`
	MaxUniqueSnapshots           *int      `json:"maxUniqueSnapshots,omitempty"`
	MaxUniqueTags                *int      `json:"maxUniqueTags,omitempty"`
	PropertySets                 *[]string `json:"propertySets,omitempty"`
	RepoLayoutRef                *string   `json:"repoLayoutRef,omitempty"`
	SnapshotVersionBehavior      *string   `json:"snapshotVersionBehavior,omitempty"`
	SuppressPomConsistencyChecks *bool     `json:"suppressPomConsistencyChecks,omitempty"`
	XrayIndex                    *bool     `json:"xrayIndex,omitempty"`
	XrayMinimumBlockedSeverity   *string   `json:"xrayMinimumBlockedSeverity,omitempty"`
	YumRootDepth                 *int      `json:"yumRootDepth,omitempty"`
}

application/vnd.org.jfrog.artifactory.repositories.LocalRepositoryConfiguration+json

func (LocalRepository) String

func (r LocalRepository) String() string

type Nuget

type Nuget struct {
	FeedContextPath     *string `json:"feedContextPath,omitempty"`
	DownloadContextPath *string `json:"downloadContextPath,omitempty"`
	V3FeedUrl           *string `json:"v3FeedUrl,omitempty"`
}

type PasswordChangeOptions

type PasswordChangeOptions struct {
	Username     *string `json:"username,omitempty"`
	OldPassword  *string `json:"oldPassword,omitempty"`
	NewPassword1 *string `json:"newPassword1,omitempty"`
	NewPassword2 *string `json:"newPassword2,omitempty"`
}

func (PasswordChangeOptions) String

func (r PasswordChangeOptions) String() string

type PasswordExpirationPolicy

type PasswordExpirationPolicy struct {
	Enabled        *bool `json:"enabled,omitempty"`
	PasswordMaxAge *int  `json:"passwordMaxAge,omitempty"`
	NotifyByEmail  *bool `json:"notifyByEmail,omitempty"`
}

func (PasswordExpirationPolicy) String

func (r PasswordExpirationPolicy) String() string

type PermissionTargets

type PermissionTargets struct {
	Name            *string     `json:"name,omitempty"`            // Optional element in create/replace queries
	IncludesPattern *string     `json:"includesPattern,omitempty"` // Optional element in create/replace queries
	ExcludesPattern *string     `json:"excludesPattern,omitempty"` // Optional element in create/replace queries
	Repositories    *[]string   `json:"repositories,omitempty"`    // Mandatory element in create/replace queries, optional in "update" queries
	Principals      *Principals `json:"principals,omitempty"`      // Optional element in create/replace queries
}

application/vnd.org.jfrog.artifactory.security.PermissionTarget+json Permissions are set/returned according to the following conventions:

m=admin; d=delete; w=deploy; n=annotate; r=read

func (PermissionTargets) String

func (r PermissionTargets) String() string

type PermissionTargetsDetails

type PermissionTargetsDetails struct {
	Name *string `json:"name,omitempty"`
	Uri  *string `json:"uri,omitempty"`
}

application/vnd.org.jfrog.artifactory.security.PermissionTargets+json

func (PermissionTargetsDetails) String

func (r PermissionTargetsDetails) String() string

type Principals

type Principals struct {
	Users  *map[string][]string `json:"users,omitempty"`
	Groups *map[string][]string `json:"groups,omitempty"`
}

type Properties

type Properties struct {
	Enabled *bool `json:"enabled,omitempty"`
}

type RemoteRepository

type RemoteRepository struct {
	Key                               *string                 `json:"key,omitempty"`
	RClass                            *string                 `json:"rclass,omitempty"` // Mandatory element in create/replace queries (optional in "update" queries)
	PackageType                       *string                 `json:"packageType,omitempty"`
	Description                       *string                 `json:"description,omitempty"`
	Notes                             *string                 `json:"notes,omitempty"`
	IncludesPattern                   *string                 `json:"includesPattern,omitempty"`
	ExcludesPattern                   *string                 `json:"excludesPattern,omitempty"`
	AllowAnyHostAuth                  *bool                   `json:"allowAnyHostAuth,omitempty"`
	ArchiveBrowsingEnabled            *bool                   `json:"archiveBrowsingEnabled,omitempty"`
	AssumedOfflinePeriodSecs          *int                    `json:"assumedOfflinePeriodSecs,omitempty"`
	BlackedOut                        *bool                   `json:"blackedOut,omitempty"`
	BlockMismatchingMimeTypes         *bool                   `json:"blockMismatchingMimeTypes,omitempty"`
	BlockXrayUnscannedArtifacts       *bool                   `json:"blockXrayUnscannedArtifacts,omitempty"`
	BypassHeadRequests                *bool                   `json:"bypassHeadRequests,omitempty"`
	ContentSynchronisation            *ContentSynchronisation `json:"contentSynchronisation,omitempty"`
	DebianTrivialLayout               *bool                   `json:"debianTrivialLayout,omitempty"`
	DockerApiVersion                  *string                 `json:"dockerApiVersion,omitempty"`
	EnableBowerSupport                *bool                   `json:"enableBowerSupport,omitempty"`
	EnableCocoaPodsSupport            *bool                   `json:"enableCocoaPodsSupport,omitempty"`
	EnableConanSupport                *bool                   `json:"enableConanSupport,omitempty"`
	EnableCookieManagement            *bool                   `json:"enableCookieManagement,omitempty"`
	EnabledChefSupport                *bool                   `json:"enabledChefSupport,omitempty"`
	EnableComposerSupport             *bool                   `json:"enableComposerSupport,omitempty"`
	EnableDebianSupport               *bool                   `json:"enableDebianSupport,omitempty"`
	EnableDistRepoSupport             *bool                   `json:"enableDistRepoSupport,omitempty"`
	EnableDockerSupport               *bool                   `json:"enableDockerSupport,omitempty"`
	EnableGemsSupport                 *bool                   `json:"enableGemsSupport,omitempty"`
	EnableGitLfsSupport               *bool                   `json:"enableGitLfsSupport,omitempty"`
	EnableNpmSupport                  *bool                   `json:"enableNpmSupport,omitempty"`
	EnableNuGetSupport                *bool                   `json:"enableNuGetSupport,omitempty"`
	EnablePuppetSupport               *bool                   `json:"enablePuppetSupport,omitempty"`
	EnablePypiSupport                 *bool                   `json:"enablePypiSupport,omitempty"`
	EnableTokenAuthentication         *bool                   `json:"enableTokenAuthentication,omitempty"`
	EnableVagrantSupport              *bool                   `json:"enableVagrantSupport,omitempty"`
	FailedRetrievalCachePeriodSecs    *int                    `json:"failedRetrievalCachePeriodSecs,omitempty"`
	FetchJarsEagerly                  *bool                   `json:"fetchJarsEagerly,omitempty"`
	FetchSourcesEagerly               *bool                   `json:"fetchSourcesEagerly,omitempty"`
	ForceNugetAuthentication          *bool                   `json:"forceNugetAuthentication,omitempty"`
	HandleReleases                    *bool                   `json:"handleReleases,omitempty"`
	HandleSnapshots                   *bool                   `json:"handleSnapshots,omitempty"`
	HardFail                          *bool                   `json:"hardFail,omitempty"`
	ListRemoteFolderItems             *bool                   `json:"listRemoteFolderItems,omitempty"`
	LocalAddress                      *string                 `json:"localAddress,omitempty"`
	MaxUniqueSnapshots                *int                    `json:"maxUniqueSnapshots,omitempty"`
	MaxUniqueTags                     *int                    `json:"maxUniqueTags,omitempty"`
	MismatchingMimeTypesOverrideList  *string                 `json:"mismatchingMimeTypesOverrideList,omitempty"`
	MissedRetrievalCachePeriodSecs    *int                    `json:"missedRetrievalCachePeriodSecs,omitempty"`
	Offline                           *bool                   `json:"offline,omitempty"`
	Password                          *string                 `json:"password,omitempty"`
	PropagateQueryParams              *bool                   `json:"propagateQueryParams,omitempty"`
	PropertySets                      *[]string               `json:"propertySets,omitempty"`
	Proxy                             *string                 `json:"proxy,omitempty"`
	RejectInvalidJars                 *bool                   `json:"rejectInvalidJars,omitempty"`
	RemoteRepoChecksumPolicyType      *string                 `json:"remoteRepoChecksumPolicyType,omitempty"`
	RepoLayoutRef                     *string                 `json:"repoLayoutRef,omitempty"`
	RetrievalCachePeriodSecs          *int                    `json:"retrievalCachePeriodSecs,omitempty"`
	ShareConfiguration                *bool                   `json:"shareConfiguration,omitempty"`
	SocketTimeoutMillis               *int                    `json:"socketTimeoutMillis,omitempty"`
	StoreArtifactsLocally             *bool                   `json:"storeArtifactsLocally,omitempty"`
	SuppressPomConsistencyChecks      *bool                   `json:"suppressPomConsistencyChecks,omitempty"`
	SynchronizeProperties             *bool                   `json:"synchronizeProperties,omitempty"`
	UnusedArtifactsCleanupEnabled     *bool                   `json:"unusedArtifactsCleanupEnabled,omitempty"`
	UnusedArtifactsCleanupPeriodHours *int                    `json:"unusedArtifactsCleanupPeriodHours,omitempty"`
	Url                               *string                 `json:"url,omitempty"`
	Username                          *string                 `json:"username,omitempty"` // Mandatory element in create/replace queries (optional in "update" queries)
	XrayIndex                         *bool                   `json:"xrayIndex,omitempty"`
	XrayMinimumBlockedSeverity        *string                 `json:"xrayMinimumBlockedSeverity,omitempty"`
	BowerRegistryURL                  *string                 `json:"bowerRegistryUrl,omitempty"`
	VcsType                           *string                 `json:"vcsType,omitempty"`
	VcsGitProvider                    *string                 `json:"vcsGitProvider,omitempty"`
	VcsGitDownloadUrl                 *string                 `json:"vcsGitDownloadUrl,omitempty"`
	ClientTLSCertificate              *string                 `json:"clientTlsCertificate,omitempty"`
	PyPiRegistryUrl                   *string                 `json:"pyPiRegistryUrl,omitempty"`
	// Deprecated since 6.9. Replaced with fields FeedContextPath, DownloadContextPath, V3FeedUrl below
	Nuget *Nuget `json:"nuget,omitempty"`
	// Replaces Nuget struct since 6.9. Mutually exclusive with Nuget field
	FeedContextPath     *string `json:"feedContextPath,omitempty"`
	DownloadContextPath *string `json:"downloadContextPath,omitempty"`
	V3FeedUrl           *string `json:"v3FeedUrl,omitempty"`
}

func (RemoteRepository) String

func (r RemoteRepository) String() string

type ReplicationConfig

type ReplicationConfig struct {
	RepoKey                *string                    `json:"-"`
	CronExp                *string                    `json:"cronExp,omitempty"`
	EnableEventReplication *bool                      `json:"enableEventReplication,omitempty"`
	Replications           *[]SingleReplicationConfig `json:"replications,omitempty"`
}

ReplicationConfig is the model for the multi replication config API endpoints. Its usage is preferred over SingleReplicationConfig as it is a more direct mapping of the replicationConfig in the UI

func (ReplicationConfig) String

func (r ReplicationConfig) String() string

type RepositoriesService

type RepositoriesService Service

func (*RepositoriesService) CreateLocal

func (s *RepositoriesService) CreateLocal(ctx context.Context, repo *LocalRepository) (*resty.Response, error)

Creates a new repository in Artifactory with the provided configuration. Since: 2.3.0 Notes: Requires Artifactory Pro An existing repository with the same key are removed from the configuration and its content is removed! Missing values are set to the default values as defined by the consumed type spec. Security: Requires an admin user

func (*RepositoriesService) CreateRemote

func (s *RepositoriesService) CreateRemote(ctx context.Context, repo *RemoteRepository) (*resty.Response, error)

Creates a new repository in Artifactory with the provided configuration. Since: 2.3.0 Notes: Requires Artifactory Pro An existing repository with the same key are removed from the configuration and its content is removed! Missing values are set to the default values as defined by the consumed type spec. Security: Requires an admin user

func (*RepositoriesService) CreateVirtual

func (s *RepositoriesService) CreateVirtual(ctx context.Context, repo *VirtualRepository) (*resty.Response, error)

Creates a new repository in Artifactory with the provided configuration. Since: 2.3.0 Notes: Requires Artifactory Pro An existing repository with the same key are removed from the configuration and its content is removed! Missing values are set to the default values as defined by the consumed type spec. Security: Requires an admin user

func (*RepositoriesService) DeleteLocal

func (s *RepositoriesService) DeleteLocal(ctx context.Context, repo string) (*resty.Response, error)

Removes a repository configuration together with the whole repository content. Since: 2.3.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*RepositoriesService) DeleteRemote

func (s *RepositoriesService) DeleteRemote(ctx context.Context, repo string) (*resty.Response, error)

Removes a repository configuration together with the whole repository content. Since: 2.3.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*RepositoriesService) DeleteVirtual

func (s *RepositoriesService) DeleteVirtual(ctx context.Context, repo string) (*resty.Response, error)

Removes a repository configuration together with the whole repository content. Since: 2.3.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*RepositoriesService) GetLocal

func (s *RepositoriesService) GetLocal(ctx context.Context, repo string) (*LocalRepository, *resty.Response, error)

Retrieves the current configuration of a repository. Since: 2.3.0 Notes: Requires Artifactory Pro Security: Requires an admin user for complete repository configuration. Non-admin users will receive only partial configuration data.

func (*RepositoriesService) GetRemote

func (s *RepositoriesService) GetRemote(ctx context.Context, repo string) (*RemoteRepository, *resty.Response, error)

Retrieves the current configuration of a repository. Since: 2.3.0 Notes: Requires Artifactory Pro Security: Requires an admin user for complete repository configuration. Non-admin users will receive only partial configuration data.

func (*RepositoriesService) GetVirtual

func (s *RepositoriesService) GetVirtual(ctx context.Context, repo string) (*VirtualRepository, *resty.Response, error)

Retrieves the current configuration of a repository. Since: 2.3.0 Notes: Requires Artifactory Pro Security: Requires an admin user for complete repository configuration. Non-admin users will receive only partial configuration data.

func (*RepositoriesService) ListRepositories

func (s *RepositoriesService) ListRepositories(ctx context.Context, opt *RepositoryListOptions) (*[]RepositoryDetails, *resty.Response, error)

Returns a list of minimal repository details for all repositories of the specified type. Since: 2.2.0 Security: Requires a privileged user (can be anonymous)

func (*RepositoriesService) UpdateLocal

func (s *RepositoriesService) UpdateLocal(ctx context.Context, repo string, repository *LocalRepository) (*resty.Response, error)

Updates an exiting repository configuration in Artifactory with the provided configuration elements. Since: 2.3.0 Notes: Requires Artifactory Pro The class of a repository (the rclass attribute cannot be updated. Security: Requires an admin user

func (*RepositoriesService) UpdateRemote

func (s *RepositoriesService) UpdateRemote(ctx context.Context, repo string, repository *RemoteRepository) (*resty.Response, error)

Updates an exiting repository configuration in Artifactory with the provided configuration elements. Since: 2.3.0 Notes: Requires Artifactory Pro The class of a repository (the rclass attribute cannot be updated. Security: Requires an admin user

func (*RepositoriesService) UpdateVirtual

func (s *RepositoriesService) UpdateVirtual(ctx context.Context, repo string, repository *VirtualRepository) (*resty.Response, error)

Updates an exiting repository configuration in Artifactory with the provided configuration elements. Since: 2.3.0 Notes: Requires Artifactory Pro The class of a repository (the rclass attribute cannot be updated. Security: Requires an admin user

type RepositoryDetails

type RepositoryDetails struct {
	Key         *string `json:"key,omitempty"`
	Type        *string `json:"type,omitempty"`
	Description *string `json:"description,omitempty"`
	URL         *string `json:"url,omitempty"`
}

func (RepositoryDetails) String

func (r RepositoryDetails) String() string

type RepositoryListOptions

type RepositoryListOptions struct {
	// Type of repositories to list.
	// Can be one of local|remote|virtual|distribution. Default: all
	Type string `url:"type,omitempty"`
}

type ReverseProxyConfig

type ReverseProxyConfig struct {
	Key                      *string `json:"key,omitempty"`
	WebServerType            *string `json:"webServerType,omitempty"`
	ArtifactoryAppContext    *string `json:"artifactoryAppContext,omitempty"`
	PublicAppContext         *string `json:"publicAppContext,omitempty"`
	ServerName               *string `json:"serverName,omitempty"`
	ServerNameExpression     *string `json:"serverNameExpression,omitempty"`
	ArtifactoryServerName    *string `json:"artifactoryServerName,omitempty"`
	ArtifactoryPort          *int    `json:"artifactoryPort,omitempty"`
	SslCertificate           *string `json:"sslCertificate,omitempty"`
	SslKey                   *string `json:"sslKey,omitempty"`
	DockerReverseProxyMethod *string `json:"dockerReverseProxyMethod,omitempty"`
	UseHttps                 *bool   `json:"useHttps,omitempty"`
	UseHttp                  *bool   `json:"useHttp,omitempty"`
	SslPort                  *int    `json:"sslPort,omitempty"`
	HttpPort                 *int    `json:"httpPort,omitempty"`
}

func (ReverseProxyConfig) String

func (r ReverseProxyConfig) String() string

type SecurityService

type SecurityService Service

func (*SecurityService) ActivateArtifactoryKeyEncryption

func (s *SecurityService) ActivateArtifactoryKeyEncryption(ctx context.Context) (*resty.Response, error)

Creates a new Artifactory encryption key and activates Artifactory key encryption. Since: 3.2.2 Notes: This is an advanced feature intended for administrators Security: Requires a valid admin user

func (*SecurityService) AddCertificate

func (s *SecurityService) AddCertificate(ctx context.Context, alias string, pem string) (*resty.Response, error)

Adds an SSL certificate. Since:5.4.0 Security: Requires an admin user

func (*SecurityService) ChangePassword

func (s *SecurityService) ChangePassword(ctx context.Context, opts *PasswordChangeOptions) (*resty.Response, error)

Changes a user's password Since: 4.4.2 Notes: Requires Artifactory Pro Security: Admin can apply this method to all users, and each (non-anonymous) user can use this method to change his own password.

func (*SecurityService) CreateApiKey

func (s *SecurityService) CreateApiKey(ctx context.Context) (*ApiKey, *resty.Response, error)

Create an API key for the current user. Returns an error if API key already exists - use regenerate API key instead. Since: 4.3.0

func (*SecurityService) CreateOrReplaceGroup

func (s *SecurityService) CreateOrReplaceGroup(ctx context.Context, groupName string, group *Group) (*resty.Response, error)

Creates a new group in Artifactory or replaces an existing group Since: 2.4.0 Notes: Requires Artifactory Pro Missing values will be set to the default values as defined by the consumed type. Security: Requires an admin user

func (*SecurityService) CreateOrReplacePermissionTargets

func (s *SecurityService) CreateOrReplacePermissionTargets(ctx context.Context, permissionName string, permissionTargets *PermissionTargets) (*resty.Response, error)

Creates a new permission target in Artifactory or replaces an existing permission target Since: 2.4.0 Notes: Requires Artifactory Pro Missing values will be set to the default values as defined by the consumed type. Security: Requires an admin user

func (*SecurityService) CreateOrReplaceUser

func (s *SecurityService) CreateOrReplaceUser(ctx context.Context, username string, user *User) (*resty.Response, error)

Creates a new user in Artifactory or replaces an existing user Since: 2.4.0 Notes: Requires Artifactory Pro Missing values will be set to the default values as defined by the consumed type. Security: Requires an admin user

func (*SecurityService) CreateToken

func (s *SecurityService) CreateToken(ctx context.Context, opts *AccessTokenOptions) (*AccessToken, *resty.Response, error)

Creates an access token Since: 5.0.0 Security: Requires a valid user

func (*SecurityService) DeactivateArtifactoryKeyEncryption

func (s *SecurityService) DeactivateArtifactoryKeyEncryption(ctx context.Context) (*resty.Response, error)

Removes the current Artifactory encryption key and deactivates Artifactory key encryption. Since: 3.2.2 Notes: This is an advanced feature intended for administrators Security: Requires a valid admin user

func (*SecurityService) DeleteCertificate

func (s *SecurityService) DeleteCertificate(ctx context.Context, alias string) (*resty.Response, error)

Deletes an SSL certificate. Since:5.4.0 Security: Requires an admin user

func (*SecurityService) DeleteGroup

func (s *SecurityService) DeleteGroup(ctx context.Context, groupName string) (*resty.Response, error)

Removes an Artifactory group. Since: 2.4.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) DeletePermissionTargets

func (s *SecurityService) DeletePermissionTargets(ctx context.Context, permissionName string) (*resty.Response, error)

Deletes an Artifactory permission target. Since: 2.4.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) DeleteUser

func (s *SecurityService) DeleteUser(ctx context.Context, username string) (*resty.Response, error)

Removes an Artifactory user. Since: 2.4.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) ExpireAllUsersPassword

func (s *SecurityService) ExpireAllUsersPassword(ctx context.Context) (*resty.Response, error)

Expires password for all users Since: 4.4.2 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) ExpireMultipleUsersPassword

func (s *SecurityService) ExpireMultipleUsersPassword(ctx context.Context, usernames []string) (*resty.Response, error)

Expires password for a list of users Since: 4.4.2 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) ExpireUserPassword

func (s *SecurityService) ExpireUserPassword(ctx context.Context, username string) (*resty.Response, error)

Expires a user's password Since: 4.4.2 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) GetApiKey

func (s *SecurityService) GetApiKey(ctx context.Context) (*ApiKey, *resty.Response, error)

Get the current user's own API key Since: 4.3.0

func (*SecurityService) GetCertificates

func (s *SecurityService) GetCertificates(ctx context.Context) (*[]CertificateDetails, *resty.Response, error)

Returns a list of installed SSL certificates. Since:5.4.0 Security: Requires an admin user

func (*SecurityService) GetEffectiveItemPermissions

func (s *SecurityService) GetEffectiveItemPermissions(ctx context.Context, repoName string, itemPath string) (*ItemPermissions, *resty.Response, error)

Returns a list of effective permissions for the specified item (file or folder). Only users and groups with some permissions on the item are returned. Supported by local and local-cached repositories. Since: 2.3.4 Notes: Requires Artifactory Pro Security: Requires a valid admin or local admin user.

func (*SecurityService) GetEncryptedPassword

func (s *SecurityService) GetEncryptedPassword(ctx context.Context) (*resty.Response, error)

Get the encrypted password of the authenticated requestor Since: 3.3.0 Security: Requires a privileged user

func (*SecurityService) GetGPGPublicKey

func (s *SecurityService) GetGPGPublicKey(ctx context.Context) (*resty.Response, error)

Gets the public key that Artifactory provides to Debian and Opkg clients to verify packages Security: Requires an authenticated user, or anonymous (if "Anonymous Access" is globally enabled)

func (*SecurityService) GetGroup

func (s *SecurityService) GetGroup(ctx context.Context, groupName string) (*Group, *resty.Response, error)

Get the details of an Artifactory Group Since: 2.4.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) GetLockedOutUsers

func (s *SecurityService) GetLockedOutUsers(ctx context.Context) (*[]string, *resty.Response, error)

If locking out users is enabled, lists all users that were locked out due to recurrent incorrect login attempts. Since: 4.4 Security: Requires a valid admin user

func (*SecurityService) GetPasswordExpirationPolicy

func (s *SecurityService) GetPasswordExpirationPolicy(ctx context.Context) (*PasswordExpirationPolicy, *resty.Response, error)

Retrieves the password expiration policy Since: 4.4.2 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) GetPermissionTargets

func (s *SecurityService) GetPermissionTargets(ctx context.Context, permissionName string) (*PermissionTargets, *resty.Response, error)

Get the details of an Artifactory Permission Target Since: 2.4.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) GetSecurityConfiguration

func (s *SecurityService) GetSecurityConfiguration(ctx context.Context) (*resty.Response, error)

Retrieve the security configuration (security.xml). Since: 2.2.0 Notes: This is an advanced feature - make sure the new configuration is really what you wanted before saving. Security: Requires a valid admin us

func (*SecurityService) GetServiceId

func (s *SecurityService) GetServiceId(ctx context.Context) (*resty.Response, error)

Provides the Service ID of an Artifactory instance or cluster. Up to version 5.5.1, the Artiafctory Service ID is formatted jf-artifactory@<id>. From version 5.5.2 the Service ID is formatted jfrt@<id>. Since: 5.0.0 Security: Requires an admin user

func (*SecurityService) GetUser

func (s *SecurityService) GetUser(ctx context.Context, username string) (*User, *resty.Response, error)

Get the details of an Artifactory user Since: 2.4.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) GetUserLockPolicy

func (s *SecurityService) GetUserLockPolicy(ctx context.Context) (*UserLockPolicy, *resty.Response, error)

Retrieves the currently configured user lock policy. Since: 4.4 Security: Requires a valid admin user

func (*SecurityService) ListGroups

func (s *SecurityService) ListGroups(ctx context.Context) (*[]GroupDetails, *resty.Response, error)

Get the groups list Since: 2.4.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) ListPermissionTargets

func (s *SecurityService) ListPermissionTargets(ctx context.Context) (*[]PermissionTargetsDetails, *resty.Response, error)

Get the permission targets list Since: 2.4.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) ListUsers

func (s *SecurityService) ListUsers(ctx context.Context) (*[]UserDetails, *resty.Response, error)

Get the users list Since: 2.4.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) RefreshToken

func (s *SecurityService) RefreshToken(ctx context.Context, opts *AccessTokenRefreshOptions) (*AccessToken, *resty.Response, error)

Refresh an access token to extend its validity. If only the access token and the refresh token are provided (and no other parameters), this pair is used for authentication. If username or any other parameter is provided, then the request must be authenticated by a token that grants admin permissions. Since: 5.0.0 Security: Requires a valid user (unless both access token and refresh token are provided)

func (*SecurityService) RegenerateApiKey

func (s *SecurityService) RegenerateApiKey(ctx context.Context) (*ApiKey, *resty.Response, error)

Regenerate an API key for the current user Since: 4.3.0

func (*SecurityService) RevokeAllApiKeys

func (s *SecurityService) RevokeAllApiKeys(ctx context.Context) (*resty.Response, error)

Revokes all API keys currently defined in the system Since: 4.3.0 Security: Requires a privileged user (Admin only)

func (*SecurityService) RevokeApiKey

func (s *SecurityService) RevokeApiKey(ctx context.Context) (*resty.Response, error)

Revokes the current user's API key Since: 4.3.0

func (*SecurityService) RevokeToken

func (s *SecurityService) RevokeToken(ctx context.Context, opts AccessTokenRevokeOptions) (*resty.Response, error)

Revoke an access token Since: 5.0.0 Security: Requires a valid user

func (*SecurityService) RevokeUserApiKey

func (s *SecurityService) RevokeUserApiKey(ctx context.Context, username string) (*resty.Response, error)

Revokes the API key of another user Since: 4.3.0 Security: Requires a privileged user (Admin only)

func (*SecurityService) SetGPGPassPhrase

func (s *SecurityService) SetGPGPassPhrase(ctx context.Context, passphrase string) (*resty.Response, error)

Sets the pass phrase required signing Debian and ipk packages using the private key Security: Requires a valid admin user

func (*SecurityService) SetGPGPrivateKey

func (s *SecurityService) SetGPGPrivateKey(ctx context.Context, gpgKey string) (*resty.Response, error)

Sets the private key that Artifactory will use to sign Debian and ipk packages Security: Requires a valid admin user

func (*SecurityService) SetGPGPublicKey

func (s *SecurityService) SetGPGPublicKey(ctx context.Context, gpgKey string) (*resty.Response, error)

Sets the public key that Artifactory provides to Debian and Opkg clients to verify packages Security: Requires a valid admin user

func (*SecurityService) SetPasswordExpirationPolicy

func (s *SecurityService) SetPasswordExpirationPolicy(ctx context.Context, policy *PasswordExpirationPolicy) (*resty.Response, error)

Sets the password expiration policy Since: 4.4.2 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) SetUserLockPolicy

func (s *SecurityService) SetUserLockPolicy(ctx context.Context, policy *PasswordExpirationPolicy) (*resty.Response, error)

Configures the user lock policy that locks users out of their account if the number of repeated incorrect login attempts exceeds the configured maximum allowed. Since: 4.4 Security: Requires a valid admin user

func (*SecurityService) UnexpireUserPassword

func (s *SecurityService) UnexpireUserPassword(ctx context.Context, username string) (*resty.Response, error)

Unexpires a user's password Since: 4.4.2 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) UnlockMultipleUsers

func (s *SecurityService) UnlockMultipleUsers(ctx context.Context, usernames []string) (*resty.Response, error)

Unlocks a list of users that were locked out due to recurrent incorrect login attempts. Since: 4.4 Security: Requires a valid admin user

func (*SecurityService) UnlockUser

func (s *SecurityService) UnlockUser(ctx context.Context, username string) (*resty.Response, error)

Unlocks a single user that was locked out due to recurrent incorrect login attempts. Since: 4.4 Security: Requires a valid admin user

func (*SecurityService) UnlockedAllUsers

func (s *SecurityService) UnlockedAllUsers(ctx context.Context) (*resty.Response, error)

Unlocks all users that were locked out due to recurrent incorrect login attempts. Since: 4.4 Security: Requires a valid admin user

func (*SecurityService) UpdateGroup

func (s *SecurityService) UpdateGroup(ctx context.Context, groupName string, group *Group) (*resty.Response, error)

Updates an exiting group in Artifactory with the provided group details. Since: 2.4.0 Notes: Requires Artifactory Pro Security: Requires an admin user

func (*SecurityService) UpdateUser

func (s *SecurityService) UpdateUser(ctx context.Context, username string, user *User) (*resty.Response, error)

Updates an exiting user in Artifactory with the provided user details. Since: 2.4.0 Notes: Requires Artifactory Pro Missing values will be set to the default values as defined by the consumed type Security: Requires an admin user

type Service

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

type SingleReplicationConfig

type SingleReplicationConfig struct {
	RepoKey                *string `json:"repoKey,omitempty"`
	URL                    *string `json:"url,omitempty"`
	SocketTimeoutMillis    *int    `json:"socketTimeoutMillis,omitempty"`
	Username               *string `json:"username,omitempty"`
	Password               *string `json:"password,omitempty"`
	Enabled                *bool   `json:"enabled,omitempty"`
	SyncDeletes            *bool   `json:"syncDeletes,omitempty"`
	SyncProperties         *bool   `json:"syncProperties,omitempty"`
	SyncStatistics         *bool   `json:"syncStatistics,omitempty"`
	PathPrefix             *string `json:"pathPrefix,omitempty"`
	CronExp                *string `json:"cronExp,omitempty"` // Only required when getting list of repositories as C*UD operations will be done through a repConfig obj
	EnableEventReplication *bool   `json:"enableEventReplication,omitempty"`
}

SingleReplicationConfig is the model of the Artifactory Replication Config

func (SingleReplicationConfig) String

func (r SingleReplicationConfig) String() string

type Source

type Source struct {
	OriginAbsenceDetection *bool `json:"originAbsenceDetection,omitempty"`
}

type Statistics

type Statistics struct {
	Enabled *bool `json:"enabled,omitempty"`
}

type SystemService

type SystemService Service

func (*SystemService) DeleteHALicenses

func (s *SystemService) DeleteHALicenses(ctx context.Context, licenseHashes HALicenseHashes) (*resty.Response, error)

Deletes a license key from an HA cluster. Since: 5.0.0 Security: Requires an admin user

func (*SystemService) GetConfiguration

func (s *SystemService) GetConfiguration(ctx context.Context) (*resty.Response, error)

Get the general configuration (artifactory.config.xml). Since: 2.2.0 Security: Requires a valid admin user

func (*SystemService) GetLicense

func (s *SystemService) GetLicense(ctx context.Context) (*LicenseDetails, *resty.Response, error)

Retrieve information about the currently installed license. Since: 3.3.0 Security: Requires a valid admin user

func (*SystemService) GetReverseProxyConfig

func (s *SystemService) GetReverseProxyConfig(ctx context.Context) (*ReverseProxyConfig, *resty.Response, error)

Retrieves the reverse proxy configuration Since: 4.3.1 Security: Requires a valid admin user

func (*SystemService) GetReverseProxySnippet

func (s *SystemService) GetReverseProxySnippet(ctx context.Context) (*resty.Response, error)

Gets the reverse proxy configuration snippet in text format Since: 4.3.1 Security: Requires a valid user (not anonymous)

func (*SystemService) GetSystemInfo

func (s *SystemService) GetSystemInfo(ctx context.Context) (*resty.Response, error)

System Info Get general system information. Since: 2.2.0 Security: Requires a valid admin user

func (*SystemService) GetVersionAndAddons

func (s *SystemService) GetVersionAndAddons(ctx context.Context) (*VersionAddOns, *resty.Response, error)

Retrieve information about the current Artifactory version, revision, and currently installed Add-ons Since: 2.2.2 Security: Requires a valid user (can be anonymous)

func (*SystemService) InstallHALicenses

func (s *SystemService) InstallHALicenses(ctx context.Context, licenses []LicenseKey) (*resty.Response, error)

Install a new license key(s) on an HA cluster. Since: 5.0.0 Security: Requires an admin user

func (*SystemService) InstallLicense

func (s *SystemService) InstallLicense(ctx context.Context, licenseKey *LicenseKey) (*resty.Response, error)

Install new license key or change the current one. Since: 3.3.0 Security: Requires a valid admin user

func (*SystemService) ListHALicenses

func (s *SystemService) ListHALicenses(ctx context.Context) (*HALicenses, *resty.Response, error)

Retrieve information about the currently installed licenses in an HA cluster. Since: 5.0.0 Security: Requires a valid admin user

func (*SystemService) Ping

func (s *SystemService) Ping(ctx context.Context) (*resty.Response, error)

Get a simple status response about the state of Artifactory Returns 200 code with an 'OK' text if Artifactory is working properly, if not will return an HTTP error code with a reason. Since: 2.3.0 Security: Requires a valid user (can be anonymous). If artifactory.ping.allowUnauthenticated=true is set in

artifactory.system.properties, then no authentication is required even if anonymous access is disabled.

func (*SystemService) UpdateReverseProxyConfig

func (s *SystemService) UpdateReverseProxyConfig(ctx context.Context, config *ReverseProxyConfig) (*resty.Response, error)

Updates the reverse proxy configuration Since: 4.3.1 Security: Requires an admin user

func (*SystemService) UpdateUrlBase

func (s *SystemService) UpdateUrlBase(ctx context.Context, newUrl string) (*resty.Response, error)

Changes the Custom URL base Since: 3.9.0 Security: Requires a valid admin user

func (*SystemService) VerifyConnection

func (s *SystemService) VerifyConnection(ctx context.Context, opt *VerifyConnectionOptions) (*resty.Response, error)

Verifies a two-way connection between Artifactory and another product Returns Success (200) if Artifactory receives a similar success code (200) from the provided endpoint. Upon error, returns 400 along with a JSON object that contains the error returned from the other system. Since: 4.15.0 Security: Requires an admin user.

type User

type User struct {
	Name                     *string   `json:"name,omitempty"`                     // Optional element in create/replace queries
	Email                    *string   `json:"email,omitempty"`                    // Mandatory element in create/replace queries, optional in "update" queries
	Password                 *string   `json:"password,omitempty"`                 // Mandatory element in create/replace queries, optional in "update" queries
	Admin                    *bool     `json:"admin,omitempty"`                    // Optional element in create/replace queries; Default: false
	ProfileUpdatable         *bool     `json:"profileUpdatable,omitempty"`         // Optional element in create/replace queries; Default: true
	DisableUIAccess          *bool     `json:"disableUIAccess,omitempty"`          // Optional element in create/replace queries; Default: false
	InternalPasswordDisabled *bool     `json:"internalPasswordDisabled,omitempty"` // Optional element in create/replace queries; Default: false
	LastLoggedIn             *string   `json:"lastLoggedIn,omitempty"`             // Read-only element
	Realm                    *string   `json:"realm,omitempty"`                    // Read-only element
	Groups                   *[]string `json:"groups,omitempty"`                   // Optional element in create/replace queries
}

application/vnd.org.jfrog.artifactory.security.User+json

func (User) String

func (r User) String() string

type UserDetails

type UserDetails struct {
	Name  *string `json:"name,omitempty"`
	Uri   *string `json:"uri,omitempty"`
	Realm *string `json:"realm,omitempty"`
}

func (UserDetails) String

func (r UserDetails) String() string

type UserLockPolicy

type UserLockPolicy struct {
	Enabled       *bool `json:"enabled,omitempty"`
	LoginAttempts *int  `json:"loginAttempts,omitempty"`
}

func (UserLockPolicy) String

func (r UserLockPolicy) String() string

type V1

type V1 struct {

	// Services used for talking to different parts of the Artifactory API.
	Repositories *RepositoriesService
	Security     *SecurityService
	System       *SystemService
	Artifacts    *ArtifactService
	// contains filtered or unexported fields
}

func NewV1

func NewV1(client *resty.Client) *V1

type VerifyConnectionOptions

type VerifyConnectionOptions struct {
	Endpoint *string `json:"endpoint,omitempty"` // Mandatory
	Username *string `json:"username,omitempty"` // Optional
	Password *string `json:"password,omitempty"` // Optional
}

type VersionAddOns

type VersionAddOns struct {
	Version  *string   `json:"version,omitempty"`
	Revision *string   `json:"revision,omitempty"`
	Addons   *[]string `json:"addons,omitempty"`
}

func (VersionAddOns) String

func (r VersionAddOns) String() string

type VirtualRepository

type VirtualRepository struct {
	Key                                           *string   `json:"key,omitempty"`
	RClass                                        *string   `json:"rclass,omitempty"` // Mandatory element in create/replace queries (optional in "update" queries)
	PackageType                                   *string   `json:"packageType,omitempty"`
	Description                                   *string   `json:"description,omitempty"`
	Notes                                         *string   `json:"notes,omitempty"`
	IncludesPattern                               *string   `json:"includesPattern,omitempty"`
	ExcludesPattern                               *string   `json:"excludesPattern,omitempty"`
	RepoLayoutRef                                 *string   `json:"repoLayoutRef,omitempty"`
	ArtifactoryRequestsCanRetrieveRemoteArtifacts *bool     `json:"artifactoryRequestsCanRetrieveRemoteArtifacts,omitempty"`
	DebianTrivialLayout                           *bool     `json:"debianTrivialLayout,omitempty"`
	DefaultDeploymentRepo                         *string   `json:"defaultDeploymentRepo,omitempty"`
	DockerApiVersion                              *string   `json:"dockerApiVersion,omitempty"`
	EnableBowerSupport                            *bool     `json:"enableBowerSupport,omitempty"`
	EnableCocoaPodsSupport                        *bool     `json:"enableCocoaPodsSupport,omitempty"`
	EnableConanSupport                            *bool     `json:"enableConanSupport,omitempty"`
	EnableComposerSupport                         *bool     `json:"enableComposerSupport,omitempty"`
	EnabledChefSupport                            *bool     `json:"enabledChefSupport,omitempty"`
	EnableDebianSupport                           *bool     `json:"enableDebianSupport,omitempty"`
	EnableDistRepoSupport                         *bool     `json:"enableDistRepoSupport,omitempty"`
	EnableDockerSupport                           *bool     `json:"enableDockerSupport,omitempty"`
	EnableGemsSupport                             *bool     `json:"enableGemsSupport,omitempty"`
	EnableGitLfsSupport                           *bool     `json:"enableGitLfsSupport,omitempty"`
	EnableNpmSupport                              *bool     `json:"enableNpmSupport,omitempty"`
	EnableNuGetSupport                            *bool     `json:"enableNuGetSupport,omitempty"`
	EnablePuppetSupport                           *bool     `json:"enablePuppetSupport,omitempty"`
	EnablePypiSupport                             *bool     `json:"enablePypiSupport,omitempty"`
	EnableVagrantSupport                          *bool     `json:"enableVagrantSupport,omitempty"`
	ExternalDependenciesEnabled                   *bool     `json:"externalDependenciesEnabled,omitempty"`
	ForceNugetAuthentication                      *bool     `json:"forceNugetAuthentication,omitempty"`
	KeyPair                                       *string   `json:"keyPair,omitempty"`
	PomRepositoryReferencesCleanupPolicy          *string   `json:"pomRepositoryReferencesCleanupPolicy,omitempty"`
	Repositories                                  *[]string `json:"repositories,omitempty"`
	VirtualRetrievalCachePeriodSecs               *int      `json:"virtualRetrievalCachePeriodSecs,omitempty"`
}

func (VirtualRepository) String

func (r VirtualRepository) String() string

Jump to

Keyboard shortcuts

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