Skip to content

Commit

Permalink
New updates to generated code
Browse files Browse the repository at this point in the history
  • Loading branch information
octokitbot committed Jan 15, 2025
1 parent 5b9d92f commit 1e61e51
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 17 deletions.
2 changes: 1 addition & 1 deletion pkg/github/kiota-lock.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"descriptionHash": "37D16F900E8FD54A55AED2274BFBD2E8A6552A4B6C8A2F8C668D5748EF7E84299244EECAE13540C67006F572CF9D36E8664402663403A02188221808E75B55DE",
"descriptionHash": "38F7E3C3D6BB9DB0C620D76E1FC82964BA22F6E1CBE49F25A1FE16B46E4A17106671665142AF54287C14355D97277B7A500C31B9D34B3B19D734C18CB4C97066",
"descriptionLocation": "../../../../../schemas/api.github.jparrowsec.cn.json",
"lockFileVersion": "1.0.0",
"kiotaVersion": "1.19.0",
Expand Down
14 changes: 7 additions & 7 deletions pkg/github/models/check_automated_security_fixes.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ import (
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
)

// CheckAutomatedSecurityFixes check Automated Security Fixes
// CheckAutomatedSecurityFixes check Dependabot security updates
type CheckAutomatedSecurityFixes struct {
// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
additionalData map[string]any
// Whether automated security fixes are enabled for the repository.
// Whether Dependabot security updates are enabled for the repository.
enabled *bool
// Whether automated security fixes are paused for the repository.
// Whether Dependabot security updates are paused for the repository.
paused *bool
}
// NewCheckAutomatedSecurityFixes instantiates a new CheckAutomatedSecurityFixes and sets the default values.
Expand All @@ -30,7 +30,7 @@ func CreateCheckAutomatedSecurityFixesFromDiscriminatorValue(parseNode i878a80d2
func (m *CheckAutomatedSecurityFixes) GetAdditionalData()(map[string]any) {
return m.additionalData
}
// GetEnabled gets the enabled property value. Whether automated security fixes are enabled for the repository.
// GetEnabled gets the enabled property value. Whether Dependabot security updates are enabled for the repository.
// returns a *bool when successful
func (m *CheckAutomatedSecurityFixes) GetEnabled()(*bool) {
return m.enabled
Expand Down Expand Up @@ -61,7 +61,7 @@ func (m *CheckAutomatedSecurityFixes) GetFieldDeserializers()(map[string]func(i8
}
return res
}
// GetPaused gets the paused property value. Whether automated security fixes are paused for the repository.
// GetPaused gets the paused property value. Whether Dependabot security updates are paused for the repository.
// returns a *bool when successful
func (m *CheckAutomatedSecurityFixes) GetPaused()(*bool) {
return m.paused
Expand Down Expand Up @@ -92,11 +92,11 @@ func (m *CheckAutomatedSecurityFixes) Serialize(writer i878a80d2330e89d26896388a
func (m *CheckAutomatedSecurityFixes) SetAdditionalData(value map[string]any)() {
m.additionalData = value
}
// SetEnabled sets the enabled property value. Whether automated security fixes are enabled for the repository.
// SetEnabled sets the enabled property value. Whether Dependabot security updates are enabled for the repository.
func (m *CheckAutomatedSecurityFixes) SetEnabled(value *bool)() {
m.enabled = value
}
// SetPaused sets the paused property value. Whether automated security fixes are paused for the repository.
// SetPaused sets the paused property value. Whether Dependabot security updates are paused for the repository.
func (m *CheckAutomatedSecurityFixes) SetPaused(value *bool)() {
m.paused = value
}
Expand Down
29 changes: 29 additions & 0 deletions pkg/github/models/enterprise_team.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ type EnterpriseTeam struct {
created_at *i336074805fc853987abe6f7fe3ad97a6a6f3077a16391fec744f671a015fbd7e.Time
// The group_id property
group_id *string
// The group_name property
group_name *string
// The html_url property
html_url *string
// The id property
Expand Down Expand Up @@ -76,6 +78,16 @@ func (m *EnterpriseTeam) GetFieldDeserializers()(map[string]func(i878a80d2330e89
}
return nil
}
res["group_name"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
val, err := n.GetStringValue()
if err != nil {
return err
}
if val != nil {
m.SetGroupName(val)
}
return nil
}
res["html_url"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
val, err := n.GetStringValue()
if err != nil {
Expand Down Expand Up @@ -163,6 +175,11 @@ func (m *EnterpriseTeam) GetFieldDeserializers()(map[string]func(i878a80d2330e89
func (m *EnterpriseTeam) GetGroupId()(*string) {
return m.group_id
}
// GetGroupName gets the group_name property value. The group_name property
// returns a *string when successful
func (m *EnterpriseTeam) GetGroupName()(*string) {
return m.group_name
}
// GetHtmlUrl gets the html_url property value. The html_url property
// returns a *string when successful
func (m *EnterpriseTeam) GetHtmlUrl()(*string) {
Expand Down Expand Up @@ -217,6 +234,12 @@ func (m *EnterpriseTeam) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a
return err
}
}
{
err := writer.WriteStringValue("group_name", m.GetGroupName())
if err != nil {
return err
}
}
{
err := writer.WriteStringValue("html_url", m.GetHtmlUrl())
if err != nil {
Expand Down Expand Up @@ -285,6 +308,10 @@ func (m *EnterpriseTeam) SetCreatedAt(value *i336074805fc853987abe6f7fe3ad97a6a6
func (m *EnterpriseTeam) SetGroupId(value *string)() {
m.group_id = value
}
// SetGroupName sets the group_name property value. The group_name property
func (m *EnterpriseTeam) SetGroupName(value *string)() {
m.group_name = value
}
// SetHtmlUrl sets the html_url property value. The html_url property
func (m *EnterpriseTeam) SetHtmlUrl(value *string)() {
m.html_url = value
Expand Down Expand Up @@ -322,6 +349,7 @@ type EnterpriseTeamable interface {
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
GetCreatedAt()(*i336074805fc853987abe6f7fe3ad97a6a6f3077a16391fec744f671a015fbd7e.Time)
GetGroupId()(*string)
GetGroupName()(*string)
GetHtmlUrl()(*string)
GetId()(*int64)
GetMembersUrl()(*string)
Expand All @@ -332,6 +360,7 @@ type EnterpriseTeamable interface {
GetUrl()(*string)
SetCreatedAt(value *i336074805fc853987abe6f7fe3ad97a6a6f3077a16391fec744f671a015fbd7e.Time)()
SetGroupId(value *string)()
SetGroupName(value *string)()
SetHtmlUrl(value *string)()
SetId(value *int64)()
SetMembersUrl(value *string)()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ func NewItemItemAutomatedSecurityFixesRequestBuilder(rawUrl string, requestAdapt
urlParams["request-raw-url"] = rawUrl
return NewItemItemAutomatedSecurityFixesRequestBuilderInternal(urlParams, requestAdapter)
}
// Delete disables automated security fixes for a repository. The authenticated user must have admin access to the repository. For more information, see "[Configuring automated security fixes](https://docs.github.com/articles/configuring-automated-security-fixes)".
// Delete disables Dependabot security updates for a repository. The authenticated user must have admin access to the repository. For more information, see "[Configuring Dependabot security updates](https://docs.github.com/articles/configuring-automated-security-fixes)".
// [API method documentation]
//
// [API method documentation]: https://docs.github.com/rest/repos/repos#disable-automated-security-fixes
// [API method documentation]: https://docs.github.com/rest/repos/repos#disable-dependabot-security-updates
func (m *ItemItemAutomatedSecurityFixesRequestBuilder) Delete(ctx context.Context, requestConfiguration *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestConfiguration[i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DefaultQueryParameters])(error) {
requestInfo, err := m.ToDeleteRequestInformation(ctx, requestConfiguration);
if err != nil {
Expand All @@ -38,11 +38,11 @@ func (m *ItemItemAutomatedSecurityFixesRequestBuilder) Delete(ctx context.Contex
}
return nil
}
// Get shows whether automated security fixes are enabled, disabled or paused for a repository. The authenticated user must have admin read access to the repository. For more information, see "[Configuring automated security fixes](https://docs.github.com/articles/configuring-automated-security-fixes)".
// Get shows whether Dependabot security updates are enabled, disabled or paused for a repository. The authenticated user must have admin read access to the repository. For more information, see "[Configuring Dependabot security updates](https://docs.github.com/articles/configuring-automated-security-fixes)".
// returns a CheckAutomatedSecurityFixesable when successful
// [API method documentation]
//
// [API method documentation]: https://docs.github.com/rest/repos/repos#check-if-automated-security-fixes-are-enabled-for-a-repository
// [API method documentation]: https://docs.github.com/rest/repos/repos#check-if-dependabot-security-updates-are-enabled-for-a-repository
func (m *ItemItemAutomatedSecurityFixesRequestBuilder) Get(ctx context.Context, requestConfiguration *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestConfiguration[i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DefaultQueryParameters])(i59ea7d99994c6a4bb9ef742ed717844297d055c7fd3742131406eea67a6404b6.CheckAutomatedSecurityFixesable, error) {
requestInfo, err := m.ToGetRequestInformation(ctx, requestConfiguration);
if err != nil {
Expand All @@ -57,10 +57,10 @@ func (m *ItemItemAutomatedSecurityFixesRequestBuilder) Get(ctx context.Context,
}
return res.(i59ea7d99994c6a4bb9ef742ed717844297d055c7fd3742131406eea67a6404b6.CheckAutomatedSecurityFixesable), nil
}
// Put enables automated security fixes for a repository. The authenticated user must have admin access to the repository. For more information, see "[Configuring automated security fixes](https://docs.github.com/articles/configuring-automated-security-fixes)".
// Put enables Dependabot security updates for a repository. The authenticated user must have admin access to the repository. For more information, see "[Configuring Dependabot security updates](https://docs.github.com/articles/configuring-automated-security-fixes)".
// [API method documentation]
//
// [API method documentation]: https://docs.github.com/rest/repos/repos#enable-automated-security-fixes
// [API method documentation]: https://docs.github.com/rest/repos/repos#enable-dependabot-security-updates
func (m *ItemItemAutomatedSecurityFixesRequestBuilder) Put(ctx context.Context, requestConfiguration *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestConfiguration[i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DefaultQueryParameters])(error) {
requestInfo, err := m.ToPutRequestInformation(ctx, requestConfiguration);
if err != nil {
Expand All @@ -72,22 +72,22 @@ func (m *ItemItemAutomatedSecurityFixesRequestBuilder) Put(ctx context.Context,
}
return nil
}
// ToDeleteRequestInformation disables automated security fixes for a repository. The authenticated user must have admin access to the repository. For more information, see "[Configuring automated security fixes](https://docs.github.com/articles/configuring-automated-security-fixes)".
// ToDeleteRequestInformation disables Dependabot security updates for a repository. The authenticated user must have admin access to the repository. For more information, see "[Configuring Dependabot security updates](https://docs.github.com/articles/configuring-automated-security-fixes)".
// returns a *RequestInformation when successful
func (m *ItemItemAutomatedSecurityFixesRequestBuilder) ToDeleteRequestInformation(ctx context.Context, requestConfiguration *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestConfiguration[i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DefaultQueryParameters])(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformationWithMethodAndUrlTemplateAndPathParameters(i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE, m.BaseRequestBuilder.UrlTemplate, m.BaseRequestBuilder.PathParameters)
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ConfigureRequestInformation(requestInfo, requestConfiguration)
return requestInfo, nil
}
// ToGetRequestInformation shows whether automated security fixes are enabled, disabled or paused for a repository. The authenticated user must have admin read access to the repository. For more information, see "[Configuring automated security fixes](https://docs.github.com/articles/configuring-automated-security-fixes)".
// ToGetRequestInformation shows whether Dependabot security updates are enabled, disabled or paused for a repository. The authenticated user must have admin read access to the repository. For more information, see "[Configuring Dependabot security updates](https://docs.github.com/articles/configuring-automated-security-fixes)".
// returns a *RequestInformation when successful
func (m *ItemItemAutomatedSecurityFixesRequestBuilder) ToGetRequestInformation(ctx context.Context, requestConfiguration *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestConfiguration[i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DefaultQueryParameters])(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformationWithMethodAndUrlTemplateAndPathParameters(i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET, m.BaseRequestBuilder.UrlTemplate, m.BaseRequestBuilder.PathParameters)
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ConfigureRequestInformation(requestInfo, requestConfiguration)
requestInfo.Headers.TryAdd("Accept", "application/json")
return requestInfo, nil
}
// ToPutRequestInformation enables automated security fixes for a repository. The authenticated user must have admin access to the repository. For more information, see "[Configuring automated security fixes](https://docs.github.com/articles/configuring-automated-security-fixes)".
// ToPutRequestInformation enables Dependabot security updates for a repository. The authenticated user must have admin access to the repository. For more information, see "[Configuring Dependabot security updates](https://docs.github.com/articles/configuring-automated-security-fixes)".
// returns a *RequestInformation when successful
func (m *ItemItemAutomatedSecurityFixesRequestBuilder) ToPutRequestInformation(ctx context.Context, requestConfiguration *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestConfiguration[i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DefaultQueryParameters])(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformationWithMethodAndUrlTemplateAndPathParameters(i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PUT, m.BaseRequestBuilder.UrlTemplate, m.BaseRequestBuilder.PathParameters)
Expand Down

0 comments on commit 1e61e51

Please sign in to comment.