GitHub

Contents

Read repository directory entries or a file with its path, type, size, SHA, encoded content and source links; select a branch, tag or commit with ref. Use view=readme for the repository README as text, or view=profile-readme with a handle or profile URL for a profile README. Each successful request costs 1 account credit, including partial results. Failed requests cost 0 credits.

get/v1/github/repo/contents

Request

  • Base URL: https://api.scrapeatlas.com
  • URL: https://api.scrapeatlas.com/v1/github/repo/contents
  • Auth: API key in header x-api-key

Query parameters

urlstring

Canonical HTTPS github.com URL of the user, repository or issue required by this route.

pathstring

Repository-relative directory or file path.

refstring

Branch name, tag or commit reference.

handlestring

GitHub handle, optionally beginning with @; 1–39 characters excluding @.

view'contents' | 'readme' | 'profile-readme'

contents (default), readme or profile-readme. path and ref apply to contents; profile-readme takes handle or a profile url.

Response

Inspect the response status and failure or coverage fields.

OR
OR

Changes

No recorded changes to this operation across all 1 revision of this API.