hovercard
Creates, updates, deletes, gets or lists a hovercard resource.
Overview
| Name | hovercard |
| Type | Resource |
| Id | github.users.hovercard |
Fields
The following fields are returned by SELECT queries:
- get_context_for_user
Response
| Name | Datatype | Description |
|---|---|---|
message | string | |
octicon | string |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_context_for_user | select | username | subject_type, subject_id | Provides hovercard information. You can find out more about someone in relation to their pull requests, issues, repositories, and organizations. The subject_type and subject_id parameters provide context for the person's hovercard, which returns more information than without the parameters. For example, if you wanted to find out more about octocat who owns the Spoon-Knife repository, you would use a subject_type value of repository and a subject_id value of 1300192 (the ID of the Spoon-Knife repository).OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
username | string | The handle for the GitHub user account. |
subject_id | string | Uses the ID for the subject_type you specified. Required when using subject_type. |
subject_type | string | Identifies which additional information you'd like to receive about the person's hovercard. Can be organization, repository, issue, pull_request. Required when using subject_id. |
SELECT examples
- get_context_for_user
Provides hovercard information. You can find out more about someone in relation to their pull requests, issues, repositories, and organizations.
The subject_type and subject_id parameters provide context for the person's hovercard, which returns more information than without the parameters. For example, if you wanted to find out more about octocat who owns the Spoon-Knife repository, you would use a subject_type value of repository and a subject_id value of 1300192 (the ID of the Spoon-Knife repository).
OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.
SELECT
message,
octicon
FROM github.users.hovercard
WHERE username = '{{ username }}' -- required
AND subject_type = '{{ subject_type }}'
AND subject_id = '{{ subject_id }}'
;