Skip to main content
GET
/
api
/
repos
/
{namespace}
/
{repo_name}
/
metadata
/
{resource}
Get entry metadata
curl --request GET \
  --url https://hub.oxen.ai/api/repos/{namespace}/{repo_name}/metadata/{resource} \
  --header 'Authorization: Bearer <token>'
{
  "status": "<string>",
  "status_message": "<string>",
  "entry": {
    "data_type": "dir",
    "extension": "<string>",
    "filename": "<string>",
    "hash": "<string>",
    "is_dir": true,
    "mime_type": "<string>",
    "size": 1,
    "is_queryable": true,
    "latest_commit": "<unknown>",
    "metadata": "<unknown>",
    "resource": "<unknown>"
  },
  "oxen_version": "<string>"
}
Get metadata for a file in a repository. This will return the file size, data type, latest commit, and other metadata about the file. The resource is the combination of the revision and the path to the file to get the metadata for. For example, main/images/image.png would get the metadata for the image.png file at the main branch.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

namespace
string
required

Namespace of the repository

repo_name
string
required

Name of the repository

resource
string
required

Path to the file/dir (including branch/commit info)

Response

Metadata for the entry found

status
string
required
status_message
string
required
entry
object
required
oxen_version
string | null