This page describes the REST endpoints that are added by the @PLUGIN@ plugin.
Please also take note of the general information on the REST API.
GET /projects/project_name/@PLUGIN@:config-project
Gets the LFS configuration for a specified project.
GET /projects/myproject/@PLUGIN@:config-project HTTP/1.0
As response an LfsProjectConfigInfo entity is returned that describes the LFS configuration for the project.
HTTP/1.1 200 OK
Content-Disposition: attachment
Content-Type: application/json;charset=UTF-8
)]}'
{
"enabled": true,
"max_object_size": 102400
"read_only": true,
"backend": "foo"
}
GET /projects/All-Projects/@PLUGIN@:config-global
Gets the global LFS configuration. May only be called on All-Projects by users having the ‘Administrate Server’ capability.
GET /projects/All-Projects/@PLUGIN@:config-global HTTP/1.0
As response an LfsGlobalConfigInfo entity is returned that describes the global LFS configuration.
HTTP/1.1 200 OK
Content-Disposition: attachment
Content-Type: application/json;charset=UTF-8
)]}'
{
"default_backend_type": "FS",
"backends": {
"foo": "FS"
},
"namespaces": {
"test-project": {
"enabled": true,
"max_object_size": 102400,
"read_only": false,
"backend": "foo"
}
}
}
PUT /projects/All-Projects/@PLUGIN@:config-global
Sets the global LFS project configuration. The configuration must be provided in the request body in an LfsGlobalConfigInput entity. If an empty body is sent, all current project settings are removed. May only be called on All-Projects by users having the ‘Administrate Server’ capability.
PUT /projects/All-Projects/@PLUGIN@:config-global HTTP/1.0
Content-Type: application/json;charset=UTF-8
{
"namespaces": {
"test-project": {
"enabled": false
}
}
}
As response an LfsGlobalConfigInfo entity is returned that describes the updated global LFS configuration.
HTTP/1.1 200 OK
Content-Disposition: attachment
Content-Type: application/json;charset=UTF-8
)]}'
{
"default_backend_type": "FS",
"backends": {
"foo": "FS"
},
"namespaces": {
"test-project": {
"enabled": false,
}
}
}
The LfsProjectConfigInfo entity describes the LFS configuration for a project.
The LfsGlobalConfigInfo entity describes the global configuration for LFS.
FS or S3.FS or S3).The LfsGlobalConfigInput entity describes the global configuration to set for LFS.