func (r *CreateForIssueCommentReq) Rel(link string, resp *CreateForIssueCommentResponse) bool {
	u := getRelLink(resp.HTTPResponse(), link)
	if u == "" {
		return false
	}
	r._url = u
	return true
}
/*
Rel updates this request to point to a relative link from resp. Returns false if
the link does not exist. Handy for paging.
package reactions
import (
	"context"
	"fmt"
	components "github.com/willabides/octo-go/components"
	requests "github.com/willabides/octo-go/requests"
	"net/http"
	"net/url"
	"strconv"
)
func CreateForCommitComment(ctx context.Context, req *CreateForCommitCommentReq, opt ...requests.Option) (*CreateForCommitCommentResponse, error) {
	opts := requests.BuildOptions(opt...)
	if req == nil {
		req = new(CreateForCommitCommentReq)
	}
	resp := &CreateForCommitCommentResponse{}
	httpReq, err := req.HTTPRequest(ctx, opt...)
	if err != nil {
		return nil, err
	}
	r, err := opts.HttpClient().Do(httpReq)
	if err != nil {
		return nil, err
	}
	err = resp.ReadResponse(r)
	if err != nil {
		return nil, err
	}
	return resp, nil
}
func (c Client) CreateForCommitComment(ctx context.Context, req *CreateForCommitCommentReq, opt ...requests.Option) (*CreateForCommitCommentResponse, error) {
	return CreateForCommitComment(ctx, req, append(c, opt...)...)
}
type CreateForCommitCommentReq struct {
	_url  string
	Owner string
	Repo  string
	CommentId   int64
	RequestBody CreateForCommitCommentReqBody
	SquirrelGirlPreview bool
}
func (r *CreateForCommitCommentReq) HTTPRequest(ctx context.Context, opt ...requests.Option) (*http.Request, error) {
	return buildHTTPRequest(ctx, buildHTTPRequestOptions{
		AllPreviews: []string{"squirrel-girl"},
		Body:        r.RequestBody,
		ExplicitURL: r._url,
		HeaderVals: map[string]*string{
			"accept":       strPtr("application/json"),
			"content-type": strPtr("application/json"),
		},
		Method:           "POST",
		Options:          opt,
		Previews:         map[string]bool{"squirrel-girl": r.SquirrelGirlPreview},
		RequiredPreviews: []string{"squirrel-girl"},
		URLPath:          fmt.Sprintf("/repos/%v/%v/comments/%v/reactions", r.Owner, r.Repo, r.CommentId),
	})
}
func (r *CreateForCommitCommentReq) Rel(link string, resp *CreateForCommitCommentResponse) bool {
	u := getRelLink(resp.HTTPResponse(), link)
	if u == "" {
		return false
	}
	r._url = u
	return true
}
type CreateForCommitCommentReqBody struct {
	Content *string `json:"content"`
}
type CreateForCommitCommentResponse struct {
	httpResponse *http.Response
	Data         components.Reaction
}
func (r *CreateForCommitCommentResponse) HTTPResponse() *http.Response {
	return r.httpResponse
}
func (r *CreateForCommitCommentResponse) ReadResponse(resp *http.Response) error {
	r.httpResponse = resp
	err := responseErrorCheck(resp, []int{200, 201})
	if err != nil {
		return err
	}
	if intInSlice(resp.StatusCode, []int{200, 201}) {
		err = unmarshalResponseBody(resp, &r.Data)
		if err != nil {
			return err
		}
	}
	return nil
}
func CreateForIssue(ctx context.Context, req *CreateForIssueReq, opt ...requests.Option) (*CreateForIssueResponse, error) {
	opts := requests.BuildOptions(opt...)
	if req == nil {
		req = new(CreateForIssueReq)
	}
	resp := &CreateForIssueResponse{}
	httpReq, err := req.HTTPRequest(ctx, opt...)
	if err != nil {
		return nil, err
	}
	r, err := opts.HttpClient().Do(httpReq)
	if err != nil {
		return nil, err
	}
	err = resp.ReadResponse(r)
	if err != nil {
		return nil, err
	}
	return resp, nil
}
func (c Client) CreateForIssue(ctx context.Context, req *CreateForIssueReq, opt ...requests.Option) (*CreateForIssueResponse, error) {
	return CreateForIssue(ctx, req, append(c, opt...)...)
}
type CreateForIssueReq struct {
	_url  string
	Owner string
	Repo  string
	IssueNumber int64
	RequestBody CreateForIssueReqBody
	SquirrelGirlPreview bool
}
func (r *CreateForIssueReq) HTTPRequest(ctx context.Context, opt ...requests.Option) (*http.Request, error) {
	return buildHTTPRequest(ctx, buildHTTPRequestOptions{
		AllPreviews: []string{"squirrel-girl"},
		Body:        r.RequestBody,
		ExplicitURL: r._url,
		HeaderVals: map[string]*string{
			"accept":       strPtr("application/json"),
			"content-type": strPtr("application/json"),
		},
		Method:           "POST",
		Options:          opt,
		Previews:         map[string]bool{"squirrel-girl": r.SquirrelGirlPreview},
		RequiredPreviews: []string{"squirrel-girl"},
		URLPath:          fmt.Sprintf("/repos/%v/%v/issues/%v/reactions", r.Owner, r.Repo, r.IssueNumber),
	})
}
func (r *CreateForIssueReq) Rel(link string, resp *CreateForIssueResponse) bool {
	u := getRelLink(resp.HTTPResponse(), link)
	if u == "" {
		return false
	}
	r._url = u
	return true
}
type CreateForIssueReqBody struct {
	Content *string `json:"content"`
}
type CreateForIssueResponse struct {
	httpResponse *http.Response
	Data         components.Reaction
}
func (r *CreateForIssueResponse) HTTPResponse() *http.Response {
	return r.httpResponse
}
func (r *CreateForIssueResponse) ReadResponse(resp *http.Response) error {
	r.httpResponse = resp
	err := responseErrorCheck(resp, []int{201})
	if err != nil {
		return err
	}
	if intInSlice(resp.StatusCode, []int{201}) {
		err = unmarshalResponseBody(resp, &r.Data)
		if err != nil {
			return err
		}
	}
	return nil
}
func CreateForIssueComment(ctx context.Context, req *CreateForIssueCommentReq, opt ...requests.Option) (*CreateForIssueCommentResponse, error) {
	opts := requests.BuildOptions(opt...)
	if req == nil {
		req = new(CreateForIssueCommentReq)
	}
	resp := &CreateForIssueCommentResponse{}
	httpReq, err := req.HTTPRequest(ctx, opt...)
	if err != nil {
		return nil, err
	}
	r, err := opts.HttpClient().Do(httpReq)
	if err != nil {
		return nil, err
	}
	err = resp.ReadResponse(r)
	if err != nil {
		return nil, err
	}
	return resp, nil
}
func (c Client) CreateForIssueComment(ctx context.Context, req *CreateForIssueCommentReq, opt ...requests.Option) (*CreateForIssueCommentResponse, error) {
	return CreateForIssueComment(ctx, req, append(c, opt...)...)
}
type CreateForIssueCommentReq struct {
	_url  string
	Owner string
	Repo  string
	CommentId   int64
	RequestBody CreateForIssueCommentReqBody
	SquirrelGirlPreview bool
}
func (r *CreateForIssueCommentReq) HTTPRequest(ctx context.Context, opt ...requests.Option) (*http.Request, error) {
	return buildHTTPRequest(ctx, buildHTTPRequestOptions{
		AllPreviews: []string{"squirrel-girl"},
		Body:        r.RequestBody,
		ExplicitURL: r._url,
		HeaderVals: map[string]*string{
			"accept":       strPtr("application/json"),
			"content-type": strPtr("application/json"),
		},
		Method:           "POST",
		Options:          opt,
		Previews:         map[string]bool{"squirrel-girl": r.SquirrelGirlPreview},
		RequiredPreviews: []string{"squirrel-girl"},
		URLPath:          fmt.Sprintf("/repos/%v/%v/issues/comments/%v/reactions", r.Owner, r.Repo, r.CommentId),
	})
}