Get the current user's rating reaction to a repository identified by UUID.

Request

GET

https://api.sourcecraft.tech/repos/id:{repo_id}/rating

Path parameters

Name

Description

repo_id

Type: string

Example: ``

Responses

200 OK

A successful response.

Body

application/json
{
  "reaction": {
    "type": "none",
    "updated_at": "2025-01-01T00:00:00Z"
  }
}

Name

Description

reaction

Type: RepositoryRatingReaction

A user's reaction that contributes to a repository rating.

Example
{
  "type": "none",
  "updated_at": "2025-01-01T00:00:00Z"
}

RepositoryRatingReaction.Type

  • none: Remove the current user's rating reaction.
  • positive_low: A low positive rating reaction. Corresponds to Like in the SourceCraft interface.
  • positive_medium: A medium positive rating reaction. Corresponds to Heart in the SourceCraft interface.
  • positive_high: A high positive rating reaction. Corresponds to Diamond in the SourceCraft interface.

Type: string

Enum: none, positive_low, positive_medium, positive_high

RepositoryRatingReaction

A user's reaction that contributes to a repository rating.

Name

Description

type

Type: RepositoryRatingReaction.Type

  • none: Remove the current user's rating reaction.
  • positive_low: A low positive rating reaction. Corresponds to Like in the SourceCraft interface.
  • positive_medium: A medium positive rating reaction. Corresponds to Heart in the SourceCraft interface.
  • positive_high: A high positive rating reaction. Corresponds to Diamond in the SourceCraft interface.

Enum: none, positive_low, positive_medium, positive_high

updated_at

Type: string<date-time>

Example: 2025-01-01T00:00:00Z

Example
{
  "type": "none",
  "updated_at": "2025-01-01T00:00:00Z"
}

default

Both Client Errors (4xx) and Server Errors (5xx) are serialized into this scheme

Body

application/json
{
  "error_code": "example",
  "message": "example",
  "request_id": "example",
  "details": null
}

Name

Description

details

Type: unknown

Example: null

error_code

Type: string

Example: example

message

Type: string

Example: example

request_id

Type: string

Example: example