get__repo
GET /repo
List Repositories
Get all repositories for the authenticated user's organization
Parameters
workspaceId
query
string
false
Optional workspace ID to filter repositories. If not provided, returns all repositories the user has access to based on their role and workspace membership.
TypeScript Client Library
public getStorageRepos = async (workspaceId?: string): Promise<GetReposResponse> => {
const queryParams = workspaceId ? `?workspaceId=${workspaceId}` : '';
return this.makeRequest<GetReposResponse>(`repo${queryParams}`, 'GET', null);
};Code Samples
# You can also use wget
curl -X GET https://backend.flashback.tech/repo \
-H 'Accept: application/json' \
-H 'Authorization: Bearer {access-token}'
# With workspaceId parameter
curl -X GET 'https://backend.flashback.tech/repo?workspaceId=workspace-123' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer {access-token}'GET https://backend.flashback.tech/repo HTTP/1.1
Host: localhost:3000
Accept: application/json
# With workspaceId parameter
GET https://backend.flashback.tech/repo?workspaceId=workspace-123 HTTP/1.1
Host: localhost:3000
Accept: application/jsonconst headers = {
'Accept':'application/json',
'Authorization':'Bearer {access-token}'
};
// Without workspaceId
fetch('https://backend.flashback.tech/repo',
{
method: 'GET',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
// With workspaceId
const workspaceId = 'workspace-123';
fetch(`https://backend.flashback.tech/repo?workspaceId=${workspaceId}`,
{
method: 'GET',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});require 'rest-client'
require 'json'
headers = {
'Accept' => 'application/json',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.get 'https://backend.flashback.tech/repo',
params: {
}, headers: headers
p JSON.parse(result)import requests
headers = {
'Accept': 'application/json',
'Authorization': 'Bearer {access-token}'
}
r = requests.get('https://backend.flashback.tech/repo', headers = headers)
print(r.json())<?php
require 'vendor/autoload.php';
$headers = array(
'Accept' => 'application/json',
'Authorization' => 'Bearer {access-token}',
);
$client = new \GuzzleHttp\Client();
// Define array of request body.
$request_body = array();
try {
$response = $client->request('GET','https://backend.flashback.tech/repo', array(
'headers' => $headers,
'json' => $request_body,
)
);
print_r($response->getBody()->getContents());
}
catch (\GuzzleHttp\Exception\BadResponseException $e) {
// handle exception or api errors.
print_r($e->getMessage());
}
// ...URL obj = new URL("https://backend.flashback.tech/repo");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Accept": []string{"application/json"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("GET", "https://backend.flashback.tech/repo", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}Example responses
200 Response
{
"success": true,
"repos": [
{
"id": "550e8400-e29b-41d4-a716-446655440000",
"name": "My Backup Repository",
"storageType": "S3",
"mode": "MIRROR",
"workspaceId": "workspace-123",
"buckets": [
{
"folder": "backups",
"master": true,
"bucketId": "123e4567-e89b-12d3-a456-426614174000",
"bucket": {
"id": "123e4567-e89b-12d3-a456-426614174000",
"name": "My Backup Bucket",
"bucket": "my-backup-bucket-2024",
"storageType": "S3",
"key": "AKIAIOSFODNN7EXAMPLE",
"secret": {
"key": "encrypted-secret-key",
"iv": "initialization-vector",
"authTag": "authentication-tag",
"message": "encrypted-message"
},
"endpoint": "https://s3.amazonaws.com",
"region": "us-east-1",
"status": "ACTIVE",
"projectId": "my-project-123",
"createdAt": "2024-01-15T09:00:00Z"
}
}
],
"apiKeys": [
{
"id": "789e0123-e45b-67d8-a901-234567890000",
"name": "Read-only key for analytics",
"accessType": "READ",
"key": "AKIAIOSFODNN7EXAMPLE",
"secret": {
"key": "encrypted-secret-key",
"iv": "initialization-vector",
"authTag": "authentication-tag",
"message": "encrypted-message"
},
"createdAt": "2024-01-15T10:30:00Z"
}
],
"aiLlms": [
{
"aiLlmId": "ai-llm-123",
"aiLlm": {
"id": "ai-llm-123",
"orgId": "org-123",
"workspaceId": "workspace-123",
"userId": "user-123",
"name": "OpenAI GPT-4",
"aiType": "OPENAI",
"endpoint": "https://api.openai.com/v1",
"key": "sk-...",
"createdAt": "2024-01-15T09:00:00Z"
}
}
],
"aiApiKeys": [
{
"id": "ai-api-key-123",
"name": "AI API Key for Repo",
"repoId": "550e8400-e29b-41d4-a716-446655440000",
"key": "ak-...",
"aiType": "OPENAI",
"createdAt": "2024-01-15T10:30:00Z",
"deletedAt": null
}
],
"createdAt": "2024-01-15T10:00:00Z",
"disabled": false
}
]
}Responses
Response Schema
Status Code 200
» success
boolean
false
none
Indicates if the request was successful
» repos
[object]
false
none
Array of storage repositories with buckets
»» id
string
false
none
Unique identifier for the repository
»» name
string
false
none
Human-readable name for the repository
»» storageType
string
false
none
Storage provider type (S3, GCS, AZURE)
»» mode
string
false
none
Repository mode (MIRROR, BACKUP)
»» workspaceId
string
false
none
Workspace ID for the repository
»» buckets
[object]
false
none
Array of bucket information in the repository
»»» folder
string
false
none
Folder path within the bucket
»»» master
boolean
false
none
Whether this is the master bucket
»»» bucketId
string
false
none
Unique identifier for the bucket
»»» bucket
object
false
none
Storage bucket details
»»»» id
string
false
none
Unique identifier for the bucket
»»»» name
string
false
none
Human-readable name for the bucket
»»»» bucket
string
false
none
Actual bucket name in cloud storage
»»»» storageType
string
false
none
Storage provider type (S3, GCS, AZURE)
»»»» key
string
false
none
Access key for the storage provider
»»»» secret
object
false
none
Encrypted secret key information
»»»»» key
string
false
none
Encrypted key data
»»»»» iv
string
false
none
Initialization vector
»»»»» authTag
string
false
none
Authentication tag
»»»»» message
string
false
none
Encrypted message
»»»» endpoint
string
false
none
Custom endpoint URL
»»»» region
string
false
none
Storage region
»»»» status
string
false
none
Bucket status
»»»» projectId
string
false
none
Project identifier (for GCS)
»»»» createdAt
string(date-time)
false
none
Creation timestamp for the bucket
»» apiKeys
[object]
false
none
Array of API keys for the repository
»»» id
string
false
none
Unique identifier for the API key
»»» name
string
false
none
Human-readable name for the API key
»»» accessType
string
false
none
Access type (READ, WRITE, ADMIN)
»»» key
string
false
none
API key identifier
»»» secret
object
false
none
Encrypted secret key information
»»»» key
string
false
none
Encrypted key data
»»»» iv
string
false
none
Initialization vector
»»»» authTag
string
false
none
Authentication tag
»»»» message
string
false
none
Encrypted message
»»» createdAt
string(date-time)
false
none
Creation timestamp for the API key
»» aiLlms
[object]
false
none
Array of AI LLM associations for the repository
»»» aiLlmId
string
false
none
Unique identifier for the AI LLM association
»»» aiLlm
object
false
none
AI LLM details
»»»» id
string
false
none
Unique identifier for the AI LLM
»»»» orgId
string
false
none
Organization ID
»»»» workspaceId
string
false
none
Workspace ID
»»»» userId
string
false
none
User ID who created the AI LLM
»»»» name
string
false
none
Human-readable name for the AI LLM
»»»» aiType
string
false
none
AI provider type (OPENAI, GOOGLE, ANTHROPIC, AWS, OTHER)
»»»» endpoint
string
false
none
API endpoint URL for the AI LLM
»»»» key
string
false
none
API key for the AI LLM (may be null)
»»»» createdAt
string(date-time)
false
none
Creation timestamp for the AI LLM
»» aiApiKeys
[object]
false
none
Array of AI API keys for the repository
»»» id
string
false
none
Unique identifier for the AI API key
»»» name
string
false
none
Human-readable name for the AI API key
»»» repoId
string
false
none
Repository ID this key belongs to
»»» key
string
false
none
AI API key identifier (may be null)
»»» aiType
string
false
none
AI provider type (OPENAI, GOOGLE, ANTHROPIC, AWS, OTHER)
»»» createdAt
string(date-time)
false
none
Creation timestamp for the AI API key
»»» deletedAt
string(date-time)
false
none
Deletion timestamp (null if not deleted)
»» createdAt
string(date-time)
false
none
Creation timestamp for the repository
»» disabled
boolean
false
none
Whether the repository is disabled
Last updated
Was this helpful?