Signed-off-by: Bryan Frimin <bryan@getprobo.com>
This commit is contained in:
Bryan Frimin
2026-03-16 17:19:02 +01:00
parent 842bbfbe97
commit 364c193d33
10 changed files with 35 additions and 35 deletions

View File

@@ -21,6 +21,6 @@ import (
type Factory struct {
IOStreams *iostreams.IOStreams
Version string
Config func() (*config.Config, error)
Version string
Config func() (*config.Config, error)
}

View File

@@ -49,16 +49,16 @@ type createResponse struct {
CreateRisk struct {
RiskEdge struct {
Node struct {
ID string `json:"id"`
Name string `json:"name"`
Category string `json:"category"`
Treatment string `json:"treatment"`
InherentLikelihood int `json:"inherentLikelihood"`
InherentImpact int `json:"inherentImpact"`
InherentRiskScore int `json:"inherentRiskScore"`
ResidualLikelihood int `json:"residualLikelihood"`
ResidualImpact int `json:"residualImpact"`
ResidualRiskScore int `json:"residualRiskScore"`
ID string `json:"id"`
Name string `json:"name"`
Category string `json:"category"`
Treatment string `json:"treatment"`
InherentLikelihood int `json:"inherentLikelihood"`
InherentImpact int `json:"inherentImpact"`
InherentRiskScore int `json:"inherentRiskScore"`
ResidualLikelihood int `json:"residualLikelihood"`
ResidualImpact int `json:"residualImpact"`
ResidualRiskScore int `json:"residualRiskScore"`
} `json:"node"`
} `json:"riskEdge"`
} `json:"createRisk"`

View File

@@ -140,7 +140,7 @@ func NewCmdList(f *cmdutil.Factory) *cobra.Command {
func(data json.RawMessage) (*api.Connection[risk], error) {
var resp struct {
Node *struct {
Typename string `json:"__typename"`
Typename string `json:"__typename"`
Risks api.Connection[risk] `json:"risks"`
} `json:"node"`
}

View File

@@ -50,21 +50,21 @@ query($id: ID!) {
type viewResponse struct {
Node *struct {
Typename string `json:"__typename"`
ID string `json:"id"`
Name string `json:"name"`
Description *string `json:"description"`
Category string `json:"category"`
Treatment string `json:"treatment"`
Note string `json:"note"`
InherentLikelihood int `json:"inherentLikelihood"`
InherentImpact int `json:"inherentImpact"`
InherentRiskScore int `json:"inherentRiskScore"`
ResidualLikelihood int `json:"residualLikelihood"`
ResidualImpact int `json:"residualImpact"`
ResidualRiskScore int `json:"residualRiskScore"`
CreatedAt string `json:"createdAt"`
UpdatedAt string `json:"updatedAt"`
Typename string `json:"__typename"`
ID string `json:"id"`
Name string `json:"name"`
Description *string `json:"description"`
Category string `json:"category"`
Treatment string `json:"treatment"`
Note string `json:"note"`
InherentLikelihood int `json:"inherentLikelihood"`
InherentImpact int `json:"inherentImpact"`
InherentRiskScore int `json:"inherentRiskScore"`
ResidualLikelihood int `json:"residualLikelihood"`
ResidualImpact int `json:"residualImpact"`
ResidualRiskScore int `json:"residualRiskScore"`
CreatedAt string `json:"createdAt"`
UpdatedAt string `json:"updatedAt"`
} `json:"node"`
}

View File

@@ -121,7 +121,7 @@ func NewCmdList(f *cmdutil.Factory) *cobra.Command {
func(data json.RawMessage) (*api.Connection[stateOfApplicability], error) {
var resp struct {
Node *struct {
Typename string `json:"__typename"`
Typename string `json:"__typename"`
StatesOfApplicability api.Connection[stateOfApplicability] `json:"statesOfApplicability"`
} `json:"node"`
}

View File

@@ -131,8 +131,8 @@ func NewCmdAdd(f *cmdutil.Factory) *cobra.Command {
input := map[string]any{
"stateOfApplicabilityId": flagSoA,
"controlId": flagControl,
"applicability": flagApplicable,
"controlId": flagControl,
"applicability": flagApplicable,
}
if flagJustification != "" {

View File

@@ -120,7 +120,7 @@ func NewCmdList(f *cmdutil.Factory) *cobra.Command {
func(data json.RawMessage) (*api.Connection[applicabilityStatement], error) {
var resp struct {
Node *struct {
Typename string `json:"__typename"`
Typename string `json:"__typename"`
ApplicabilityStatements api.Connection[applicabilityStatement] `json:"applicabilityStatements"`
} `json:"node"`
}

View File

@@ -137,7 +137,7 @@ func NewCmdList(f *cmdutil.Factory) *cobra.Command {
func(data json.RawMessage) (*api.Connection[profile], error) {
var resp struct {
Node *struct {
Typename string `json:"__typename"`
Typename string `json:"__typename"`
Profiles api.Connection[profile] `json:"profiles"`
} `json:"node"`
}

View File

@@ -110,7 +110,7 @@ func NewCmdList(f *cmdutil.Factory) *cobra.Command {
func(data json.RawMessage) (*api.Connection[webhookEvent], error) {
var resp struct {
Node *struct {
Typename string `json:"__typename"`
Typename string `json:"__typename"`
Events api.Connection[webhookEvent] `json:"events"`
} `json:"node"`
}