// Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT.

package tangled

// schema: sh.tangled.repo.tag

import (
	"bytes"
	"context"

	"github.com/bluesky-social/indigo/lex/util"
)

const (
	RepoTagNSID = "sh.tangled.repo.tag"
)

// RepoTag calls the XRPC method "sh.tangled.repo.tag".
//
// repo: Repository identifier in format 'did:plc:.../repoName'
// tag: Name of tag, such as v1.3.0
func RepoTag(ctx context.Context, c util.LexClient, repo string, tag string) ([]byte, error) {
	buf := new(bytes.Buffer)

	params := map[string]interface{}{}
	params["repo"] = repo
	params["tag"] = tag
	if err := c.LexDo(ctx, util.Query, "", "sh.tangled.repo.tag", params, nil, buf); err != nil {
		return nil, err
	}

	return buf.Bytes(), nil
}
