Retrieve a file
curl --request GET \
--url https://api.zerogpu.ai/v1/files/{file_id} \
--header 'x-api-key: <api-key>' \
--header 'x-project-id: <api-key>'import requests
url = "https://api.zerogpu.ai/v1/files/{file_id}"
headers = {
"x-api-key": "<api-key>",
"x-project-id": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'x-api-key': '<api-key>', 'x-project-id': '<api-key>'}
};
fetch('https://api.zerogpu.ai/v1/files/{file_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));falsepackage main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.zerogpu.ai/v1/files/{file_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("x-project-id", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}require 'uri'
require 'net/http'
url = URI("https://api.zerogpu.ai/v1/files/{file_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
request["x-project-id"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"object": "file",
"bytes": 123,
"created_at": 123,
"filename": "<string>",
"purpose": "batch",
"status": "uploaded",
"status_details": "<string>",
"expires_at": 123,
"is_error": true
}Batch API
Retrieve file
Interactive playground for GET /v1/files/.
GET
/
v1
/
files
/
{file_id}
Retrieve a file
curl --request GET \
--url https://api.zerogpu.ai/v1/files/{file_id} \
--header 'x-api-key: <api-key>' \
--header 'x-project-id: <api-key>'import requests
url = "https://api.zerogpu.ai/v1/files/{file_id}"
headers = {
"x-api-key": "<api-key>",
"x-project-id": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'x-api-key': '<api-key>', 'x-project-id': '<api-key>'}
};
fetch('https://api.zerogpu.ai/v1/files/{file_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));falsepackage main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.zerogpu.ai/v1/files/{file_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("x-project-id", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}require 'uri'
require 'net/http'
url = URI("https://api.zerogpu.ai/v1/files/{file_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
request["x-project-id"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"object": "file",
"bytes": 123,
"created_at": 123,
"filename": "<string>",
"purpose": "batch",
"status": "uploaded",
"status_details": "<string>",
"expires_at": 123,
"is_error": true
}Look up metadata for one file (
filename, bytes, purpose, status) without downloading the body. Use Download file for the JSONL content.
Full reference: Files API.Path Parameters
Response
File object
Prefixed with file-.
Available options:
file Uploads use batch; batch results use batch_output.
Available options:
batch, batch_output Available options:
uploaded, processed, error ZeroGPU extension. true on batch error output files only.

