Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing fields in structure #3214

Closed
AbhishekAg opened this issue Jul 20, 2024 · 6 comments · Fixed by #3216
Closed

Missing fields in structure #3214

AbhishekAg opened this issue Jul 20, 2024 · 6 comments · Fixed by #3216

Comments

@AbhishekAg
Copy link
Contributor

  1. https://docs.github.com/en/enterprise-cloud@latest/rest/orgs/custom-roles?apiVersion=2022-11-28#list-custom-repository-roles-in-an-organization
    File: orgs_custom_roles.go
    Problem: Missing fields in the CustomRepoRoles structure

I have modified the structure to below struct as per the schema.

type CustomRepoRoles struct {
	ID          *int64        `json:"id,omitempty"`
	Name        *string       `json:"name,omitempty"`
	Description *string       `json:"description,omitempty"`
	BaseRole    *string       `json:"base_role,omitempty"`
	Permissions []string      `json:"permissions,omitempty"`
	Org         *Organization `json:"organization,omitempty"`
	CreatedAt   *Timestamp    `json:"created_at,omitempty"`
	UpdatedAt   *Timestamp    `json:"updated_at,omitempty"`
}
  1. https://docs.github.com/en/enterprise-cloud@latest/rest/orgs/organization-roles?apiVersion=2022-11-28#get-all-organization-roles-for-an-organization
    File: orgs_custom_roles.go
    Problem: Missing fields in the CustomOrgRoles structure

I have modified the structure to below struct as per the schema.

type CustomOrgRoles struct {
	ID          *int64        `json:"id,omitempty"`
	Name        *string       `json:"name,omitempty"`
	Description *string       `json:"description,omitempty"`
	Permissions []string      `json:"permissions,omitempty"`
	Org         *Organization `json:"organization,omitempty"`
	CreatedAt   *Timestamp    `json:"created_at,omitempty"`
	UpdatedAt   *Timestamp    `json:"updated_at,omitempty"`
	Source      *string       `json:"source,omitempty"`
	BaseRole    *string       `json:"base_role,omitempty"`
}

I want someone to commit the changes in go-github codebase

@gmlewis
Copy link
Collaborator

gmlewis commented Jul 20, 2024

You don't want to create a PR even though you have already done all the work?

@AbhishekAg
Copy link
Contributor Author

AbhishekAg commented Jul 21, 2024

@gmlewis I don't have permissions to push the changes for the review.

Below are my changes
custom_roles_changes.txt

@gmlewis
Copy link
Collaborator

gmlewis commented Jul 21, 2024

This would be a great PR for any new contributor to this repo or a new Go developer.
All contributions are greatly appreciated!

Feel free to volunteer for any issue and the issue can be assigned to you so that others don't attempt to duplicate the work.

Please check out our CONTRIBUTING.md guide to get started. (In particular, please remember to go generate ./... and don't use force-push to your PRs.)

Thank you!

@AbhishekAg
Copy link
Contributor Author

@gmlewis I have signed the agreement, but still I am unable to submit my changes for review.

remote: Permission to google/go-github.git denied to AbhishekAg.
fatal: unable to access 'https://github.com/google/go-github.git/': The requested URL returned error: 403

@gmlewis
Copy link
Collaborator

gmlewis commented Jul 21, 2024

To make a PR, you first make a fork of the repo.
I believe this is explained in the CONTRIBUTING.md guide. Have you read that guide?

@AbhishekAg
Copy link
Contributor Author

@gmlewis I am able to open the PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants