Skip to content

Get an autolink reference of a repository

GET
/repos/{owner}/{repo}/autolinks/{autolink_id}

This returns a single autolink reference by ID that was configured for the given repository.

Information about autolinks are only available to repository administrators.

API method documentation

owner
required
string

The account owner of the repository. The name is not case sensitive.

repo
required
string

The name of the repository without the .git extension. The name is not case sensitive.

autolink_id
required
integer

The unique identifier of the autolink.

Response

Media type application/json
Autolink reference

An autolink reference.

object
id
required
integer
key_prefix
required

The prefix of a key that is linkified.

string
url_template
required

A template for the target URL that is generated if a key was found.

string
is_alphanumeric
required

Whether this autolink reference matches alphanumeric characters. If false, this autolink reference only matches numeric characters.

boolean
updated_at
string format: date-time
nullable
Examples
Example default
{
"id": 1,
"key_prefix": "TICKET-",
"url_template": "https://example.com/TICKET?query=<num>",
"is_alphanumeric": true
}

Resource not found

Media type application/json
Basic Error

Basic Error

object
message
string
documentation_url
string
url
string
status
string
Example generated
{
"message": "example",
"documentation_url": "example",
"url": "example",
"status": "example"
}