GitHub Repos Get Readme In Directory

1 credits/call
ae_github_repos_get_readme_in_directory

Get the README file from a specific directory in a GitHub repository, in raw or rendered HTML format.

Productivity
1 credits/call

Pricing

1 credits/call
ConditionCharge
Each call1 credits/call

Parameters

Optional parameters use the platform defaults when omitted.

ParameterTypeRequiredDescriptionDefault
dirstringYesThe alternate path to look for a README file—
refstringNoThe name of the commit/branch/tag. Default: the repository’s default branch.—
repostringYesThe name of the repository without the `.git` extension. The name is not case sensitive.—
ownerstringYesThe account owner of the repository. The name is not case sensitive.—

Invocation example

Copy the request and explore its response example.

POST/agent-api/v1/tool/executeX-Api-Key
Request coderequest.sh
curl --request POST \
  --url 'https://agentearth.ai/agent-api/v1/tool/execute?tool_name=ae_github_repos_get_readme_in_directory' \
  --header "X-Api-Key: $AGENTEARTH_API_KEY" \
  --header 'Content-Type: application/json' \
  --data-raw '{
  "params": {
    "dir": ".",
    "owner": "geifmany",
    "repo": "selectivenet"
  }
}'
Response exampleresponse.json
JSONPartial content
{
  "_links": {
    "git": "https://api.github.com/repos/geifmany/selectivenet/git/blobs/81a5002d685a5b2da88535fb6d1b388916dec879",
    "html": "https://github.com/geifmany/selectivenet/blob/master/README.md",
    "self": "https://api.github.com/repos/geifmany/selectivenet/contents/README.md?ref=master"
  },
  "content": "IyBTZWxlY3RpdmVOZXQKQ29kZSBmb3IgdGhlIElDTUwgMjAxOSBwYXBlciAi\nU2VsZWN0aXZlTmV0OiBBIERlZXAgTmV1cmFsIE5ldHdvcmsgd2l0aCBhbiBJ\nbnRlZ3JhdGVkIFJlamVjdCBPcHRpb24iCta/ClRvIHJ1biBhbiBleHBlcmlt\nZW50IHJ1biB0cmFpbi5weSAtLW1vZGVsX25hbWUgW25hbWVdIC0tYmFzZWxp\nbmUgW25hbWVd",
  "download_url": "https://raw.githubusercontent.com/geifmany/selectivenet/master/README.md",
  "name": "README.md",
  "type": "file",
  "url": "https://api.github.com/repos/geifmany/selectivenet/contents/README.md?ref=master"
}

This example shows part of the response. Copied content is valid JSON.