Update Repository
Deprecated
Endpoint is deprecated, please use PATCH /repos/{org_slug}/{repo_slug} instead
Request
PATCH
https://api.sourcecraft.tech/{org_slug}/{repo_slug}
Path parameters
|
Name |
Description |
|
org_slug |
Type: string Example: `` |
|
repo_slug |
Type: string Example: `` |
Query parameters
|
Name |
Description |
|
silent |
Type: boolean Flag for update without any notifications. NOT IMPLEMENTED YET. |
Body
application/json
{
"description": "example",
"default_branch": "example",
"visibility": "public",
"links": [
{
"link": "example",
"type": "social_network"
}
],
"template_type": "not_a_template"
}
|
Name |
Description |
|
default_branch |
Type: string Example: |
|
description |
Type: string Example: |
|
links |
Type: Link[] Example
|
|
template_type |
Type: RepoTemplate Enum: |
|
visibility |
Type: Repository.Visibility Enum: |
Repository.Visibility
Type: string
Enum: public, internal, private
Link.LinkType
Type: string
Enum: social_network, homepage, email, telegram
Link
|
Name |
Description |
|
link |
Type: string Example: |
|
type |
Type: Link.LinkType Enum: |
Example
{
"link": "example",
"type": "social_network"
}
RepoTemplate
Type: string
Enum: not_a_template, organizational, system
Responses
200 OK
A successful response.
Body
application/json
{
"id": "example",
"name": "example",
"default_branch": "example",
"organization": {
"id": "example",
"slug": "example"
},
"slug": "example",
"template_type": "not_a_template",
"is_empty": true,
"description": "example",
"visibility": "public",
"logo": {
"url": "example"
},
"clone_url": {
"https": "example",
"ssh": "example"
},
"web_url": "example",
"links": [
{
"link": "example",
"type": "social_network"
}
],
"counters": {
"forks": "example",
"pull_requests": "example",
"issues": "example",
"tags": "example",
"branches": "example"
},
"last_updated": "2025-01-01T00:00:00Z",
"language": {
"name": "example",
"color": "example"
},
"parent": {
"id": "example",
"slug": "example",
"organization": null
},
"migration_source": {
"url": "example",
"domain": "example"
}
}
|
Name |
Description |
|
clone_url |
Type: CloneURL Example
|
|
counters |
Type: RepositoryCounters Example
|
|
default_branch |
Type: string Example: |
|
description |
Type: string Example: |
|
id |
Type: string Example: |
|
is_empty |
Type: boolean |
|
language |
Type: Language Example
|
|
last_updated |
Type: string<date-time> Example: |
|
links |
Type: Link[] Example
|
|
logo |
Type: Image Example
|
|
migration_source |
Type: MigrationSource Example
|
|
name |
Type: string Example: |
|
organization |
Type: OrganizationEmbedded Example
|
|
parent |
Type: RepositoryEmbedded Example
|
|
slug |
Type: string Example: |
|
template_type |
Type: RepoTemplate Enum: |
|
visibility |
Type: Repository.Visibility Enum: |
|
web_url |
Type: string Example: |
OrganizationEmbedded
|
Name |
Description |
|
id |
Type: string Example: |
|
slug |
Type: string Example: |
Example
{
"id": "example",
"slug": "example"
}
Image
|
Name |
Description |
|
url |
Type: string Example: |
Example
{
"url": "example"
}
CloneURL
|
Name |
Description |
|
https |
Type: string Example: |
|
ssh |
Type: string Example: |
Example
{
"https": "example",
"ssh": "example"
}
RepositoryCounters
|
Name |
Description |
|
branches |
Type: string<uint64> Example: |
|
forks |
Type: string<uint64> Example: |
|
issues |
Type: string<uint64> Example: |
|
pull_requests |
Type: string<uint64> Example: |
|
tags |
Type: string<uint64> Example: |
Example
{
"forks": "example",
"pull_requests": "example",
"issues": "example",
"tags": "example",
"branches": "example"
}
Language
|
Name |
Description |
|
color |
Type: string Example: |
|
name |
Type: string Example: |
Example
{
"name": "example",
"color": "example"
}
RepositoryEmbedded
|
Name |
Description |
|
id |
Type: string Example: |
|
organization |
Type: OrganizationEmbedded Example
|
|
slug |
Type: string Example: |
Example
{
"id": "example",
"slug": "example",
"organization": {
"id": "example",
"slug": "example"
}
}
MigrationSource
|
Name |
Description |
|
domain |
Type: string Example: |
|
url |
Type: string Example: |
Example
{
"url": "example",
"domain": "example"
}
default
Both Client Errors (4xx) and Server Errors (5xx) are serialized into this scheme
Body
application/json
{
"error_code": "example",
"message": "example",
"request_id": "example",
"details": {}
}
|
Name |
Description |
||
|
details |
Type: Optional details. Exact structure depends on error_code
Example
|
||
|
error_code |
Type: string Example: |
||
|
message |
Type: string Example: |
||
|
request_id |
Type: string Example: |
No longer supported, please use an alternative and newer version.