Create Repository

Creates a new repository in Artifactory with the provided configuration. Supported by local, remote, virtual, and Federated repositories.

Since: 2.3.0

Supported JFrog Subscriptions: Local, remote, and virtual repositories require a Pro subscription. Federated repositories are supported from Artifactory 7.18.3 and require an Enterprise X or Enterprise+ subscription.

If a repository with the specified repoKey already exists, the call fails with a 400 response. Missing values are set to default values as defined by the consumed type spec.

For a Smart Remote Repository, set the enabled flag to true under contentSynchronisation. To enable CDN Distribution, set the cdnRedirect flag; this applies to Artifactory Cloud and requires an Enterprise or Enterprise+ license.

Security: Requires an admin user.

Additional examples of repository configuration can be found at: https://docs.jfrog.com/integrations/docs/configuration-json-files#repository-configuration-json

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
string
required

The repository key

Body Params

Full repository configuration JSON for the repository class (rclass). Use the shape for local, remote, virtual, or federated matching your rclass—each has its own packageType set and fields (do not mix them). Vendor Content-Type values (application/vnd.org.jfrog.artifactory.repositories.*+json) or plain application/json use the same JSON shapes defined in the schemas below.

Local repository configuration JSON. Vendor media type application/vnd.org.jfrog.artifactory.repositories.LocalRepositoryConfiguration+json. Required vs optional fields and defaults are described on each property below.

string
required

Repository key (mandatory on create).

string
enum
required

Must be local.

Allowed:
string

Project key; when assigning the repo to a project, environments is mandatory.

environments
array of strings

Mandatory when assigning repository to a project.

environments
string
enum

Allowed packageType values for local repositories.

string

Public description of the repository.

string

Internal notes.

string

Default **/*; empty string also includes everything.

string
string

Default maven-2-default where applicable.

boolean
string
enum

Checksum policy (local and federated repository configuration).

Allowed:
boolean

Default true.

boolean

Default true.

integer
integer
string
enum

Maven SNAPSHOT naming; default unique from 7.41 (affects local and federated).

Allowed:
boolean
boolean
boolean
propertySets
array of strings
propertySets
boolean
boolean
integer
string
enum

Default V2 (Docker API version).

Allowed:
string
enum
Allowed:
string
optionalIndexCompressionFormats
array of strings
optionalIndexCompressionFormats
string
string

Artifactory Cloud; Enterprise or Enterprise+ license when enabled.

string
string
string
boolean
boolean
boolean
boolean
string

Default false; applies to all repository types excluding CocoaPods, Git LFS, NuGet V2, Opkg, Rust, Vagrant, VCS.

contentSynchronisation
object

Smart Remote Repository; set enabled under this object.

Headers
string
enum
Defaults to application/json

Generated from available response content types

Allowed:
string
enum
Defaults to application/json

Generated from available request content types

Allowed:
Responses

Language
Credentials
:
URL
LoadingLoading…
Response
Choose an example:
text/plain
application/json