Create Content Source

Create Content Source
Create a Content source

Returns the new content source

Request
URI
POST
https://{vcfa-fqdn}/content/api/sources
COPY
Query Parameters
string
apiVersion
Optional

The version of the API in yyyy-MM-dd format (UTC). For versioning information, please refer to /content/api/about


Request Body
ContentSource of type(s) application/json
Required  

Show optional properties

{
    "id": "string",
    "name": "string",
    "typeId": "string",
    "projectId": "string"
}
{
    "id": "string",
    "name": "string",
    "description": "string",
    "typeId": "string",
    "createdAt": "string",
    "createdBy": "string",
    "lastUpdatedAt": "string",
    "lastUpdatedBy": "string",
    "projectId": "string",
    "config": {},
    "orgId": "string",
    "syncEnabled": false
}
string As uuid As uuid
id
Required  

Content Source id

string
name
Required  

Content Source name

string
description
Optional

Content Source description

string
typeId
Required  

Content Source type

Enumeration: com.github, com.github.enterprise, com.gitlab, com.gitlab.enterprise, org.bitbucket
string As date-time As date-time
createdAt
Read-Only  

Creation time

string
createdBy
Read-Only  

Created By

string As date-time As date-time
lastUpdatedAt
Read-Only  

Update time

string
lastUpdatedBy
Read-Only  

Updated By

string
projectId
Required  

Associated projects

object
config
Optional

config

string
orgId
Read-Only  

Associated org

boolean
syncEnabled
Optional

Is Sync Enabled

Authentication
This operation uses the following authentication methods.
Responses
201

Created content source

Returns ContentSource of type(s) application/json
{
    "id": "string",
    "name": "string",
    "description": "string",
    "typeId": "string",
    "createdAt": "string",
    "createdBy": "string",
    "lastUpdatedAt": "string",
    "lastUpdatedBy": "string",
    "projectId": "string",
    "config": {},
    "orgId": "string",
    "syncEnabled": false
}
string As uuid As uuid
id
Required  

Content Source id

string
name
Required  

Content Source name

string
description
Optional

Content Source description

string
typeId
Required  

Content Source type

Enumeration: com.github, com.github.enterprise, com.gitlab, com.gitlab.enterprise, org.bitbucket
string As date-time As date-time
createdAt
Read-Only  

Creation time

string
createdBy
Read-Only  

Created By

string As date-time As date-time
lastUpdatedAt
Read-Only  

Update time

string
lastUpdatedBy
Read-Only  

Updated By

string
projectId
Required  

Associated projects

object
config
Optional

config

string
orgId
Read-Only  

Associated org

boolean
syncEnabled
Optional

Is Sync Enabled


400

Invalid request data

Returns ContentSource of type(s) application/json
"ContentSource Object"
string As uuid As uuid
id
Required  

Content Source id

string
name
Required  

Content Source name

string
description
Optional

Content Source description

string
typeId
Required  

Content Source type

Enumeration: com.github, com.github.enterprise, com.gitlab, com.gitlab.enterprise, org.bitbucket
string As date-time As date-time
createdAt
Read-Only  

Creation time

string
createdBy
Read-Only  

Created By

string As date-time As date-time
lastUpdatedAt
Read-Only  

Update time

string
lastUpdatedBy
Read-Only  

Updated By

string
projectId
Required  

Associated projects

object
config
Optional

config

string
orgId
Read-Only  

Associated org

boolean
syncEnabled
Optional

Is Sync Enabled


403

Invalid project id or integration id

Returns ContentSource of type(s) application/json
"ContentSource Object"
string As uuid As uuid
id
Required  

Content Source id

string
name
Required  

Content Source name

string
description
Optional

Content Source description

string
typeId
Required  

Content Source type

Enumeration: com.github, com.github.enterprise, com.gitlab, com.gitlab.enterprise, org.bitbucket
string As date-time As date-time
createdAt
Read-Only  

Creation time

string
createdBy
Read-Only  

Created By

string As date-time As date-time
lastUpdatedAt
Read-Only  

Update time

string
lastUpdatedBy
Read-Only  

Updated By

string
projectId
Required  

Associated projects

object
config
Optional

config

string
orgId
Read-Only  

Associated org

boolean
syncEnabled
Optional

Is Sync Enabled


Code Samples
COPY
                    curl -X POST -H 'Authorization: <value>' -H 'Content-Type: application/json' -d '{"id":"string","name":"string","projectId":"string","typeId":"string"}' https://{api_host}/content/api/sources