跳转到内容
Try Gitea Cloud ☁️ for 30 days → Accelerate your Development & Deploys!

Gets the tag object of an annotated tag (not lightweight tags)

GET
/repos/{owner}/{repo}/git/tags/{sha}
curl --request GET \
--url https://gitea.com/api/v1/repos/example/example/git/tags/example \
--header 'Authorization: Basic <credentials>'
owner
required
string

Owner of the repo

repo
required
string

Name of the repo

sha
required
string

Sha of the tag. The Git tags API only supports annotated tag objects, not lightweight tags.

AnnotatedTag

Media typeapplication/json

AnnotatedTag represents an annotated tag

object
message

The message associated with the annotated tag

string
object

AnnotatedTagObject contains meta information of the tag object

object
sha

The SHA hash of the tagged object

string
type

The type of the tagged object (e.g., commit, tree)

string
url

The URL to access the tagged object

string
sha

The SHA hash of the annotated tag

string
tag

The name of the annotated tag

string
tagger
CommitUser contains information of a user in the context of a commit.
object
date

Date is the commit date in string format

string
email
string format: email
name

Name is the person’s name

string
url

The URL to access the annotated tag

string
verification

PayloadCommitVerification represents the GPG verification of a commit

object
payload

The signed payload content

string
reason

The reason for the verification status

string
signature

The GPG signature of the commit

string
signer

PayloadUser represents the author or committer of a commit

object
email
string format: email
name

Full name of the commit author

string
username

Username of the user

string
verified

Whether the commit signature is verified

boolean
Examplegenerated
{
"message": "example",
"object": {
"sha": "example",
"type": "example",
"url": "example"
},
"sha": "example",
"tag": "example",
"tagger": {
"date": "example",
"email": "hello@example.com",
"name": "example"
},
"url": "example",
"verification": {
"payload": "example",
"reason": "example",
"signature": "example",
"signer": {
"email": "hello@example.com",
"name": "example",
"username": "example"
},
"verified": true
}
}

APIError is error format response

Media typeapplication/json
message
string
url
string

APINotFound is a not found empty response

Media typeapplication/json