Skip to content

Commit

Permalink
refactor: changed cmd to command (#9)
Browse files Browse the repository at this point in the history
  • Loading branch information
graza-io authored Dec 8, 2023
1 parent 2667250 commit 2344d12
Show file tree
Hide file tree
Showing 17 changed files with 944 additions and 23 deletions.
7 changes: 6 additions & 1 deletion .openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ docs/ExecutionStepExecution.md
docs/ExecutionStepExecutionOutput.md
docs/ExecutionStepExecutionStepForEach.md
docs/ExecutionStepStatus.md
docs/FlowpipeRequire.md
docs/FpPipeline.md
docs/FpPipelineParam.md
docs/FpTrigger.md
Expand All @@ -31,6 +32,7 @@ docs/ListTriggerResponse.md
docs/ListVariableResponse.md
docs/Mod.md
docs/ModApi.md
docs/ModVersionConstraint.md
docs/ModconfigNextStepAction.md
docs/ModconfigOutput.md
docs/ModconfigPipelineOutput.md
Expand All @@ -46,6 +48,7 @@ docs/Process.md
docs/ProcessApi.md
docs/ProcessEventLog.md
docs/ProcessOutputData.md
docs/Require.md
docs/TriggerApi.md
docs/Variable.md
docs/VariableApi.md
Expand All @@ -64,6 +67,7 @@ model_execution_step_execution.go
model_execution_step_execution_output.go
model_execution_step_execution_step_for_each.go
model_execution_step_status.go
model_flowpipe_require.go
model_fp_pipeline.go
model_fp_pipeline_param.go
model_fp_trigger.go
Expand All @@ -73,6 +77,7 @@ model_list_process_response.go
model_list_trigger_response.go
model_list_variable_response.go
model_mod.go
model_mod_version_constraint.go
model_modconfig_next_step_action.go
model_modconfig_output.go
model_modconfig_pipeline_output.go
Expand All @@ -86,7 +91,7 @@ model_perr_error_model.go
model_process.go
model_process_event_log.go
model_process_output_data.go
model_require.go
model_variable.go
response.go
test/api_mod_test.go
utils.go
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ All URIs are relative to *https://localhost/api/v0*
Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*ModApi* | [**Get**](docs/ModApi.md#get) | **Get** /mod/{mod_name} | Get mod
*PipelineApi* | [**Cmd**](docs/PipelineApi.md#cmd) | **Post** /pipeline/{pipeline_name}/cmd | Execute a pipeline command
*PipelineApi* | [**Command**](docs/PipelineApi.md#command) | **Post** /pipeline/{pipeline_name}/command | Execute a pipeline command
*PipelineApi* | [**Get**](docs/PipelineApi.md#get) | **Get** /pipeline/{pipeline_name} | Get pipeline
*PipelineApi* | [**List**](docs/PipelineApi.md#list) | **Get** /pipeline | List pipelines
*ProcessApi* | [**Get**](docs/ProcessApi.md#get) | **Get** /process/{process_id} | Get process
Expand Down Expand Up @@ -110,6 +110,7 @@ Class | Method | HTTP request | Description
- [ExecutionStepExecutionOutput](docs/ExecutionStepExecutionOutput.md)
- [ExecutionStepExecutionStepForEach](docs/ExecutionStepExecutionStepForEach.md)
- [ExecutionStepStatus](docs/ExecutionStepStatus.md)
- [FlowpipeRequire](docs/FlowpipeRequire.md)
- [FpPipeline](docs/FpPipeline.md)
- [FpPipelineParam](docs/FpPipelineParam.md)
- [FpTrigger](docs/FpTrigger.md)
Expand All @@ -119,6 +120,7 @@ Class | Method | HTTP request | Description
- [ListTriggerResponse](docs/ListTriggerResponse.md)
- [ListVariableResponse](docs/ListVariableResponse.md)
- [Mod](docs/Mod.md)
- [ModVersionConstraint](docs/ModVersionConstraint.md)
- [ModconfigNextStepAction](docs/ModconfigNextStepAction.md)
- [ModconfigOutput](docs/ModconfigOutput.md)
- [ModconfigPipelineOutput](docs/ModconfigPipelineOutput.md)
Expand All @@ -132,6 +134,7 @@ Class | Method | HTTP request | Description
- [Process](docs/Process.md)
- [ProcessEventLog](docs/ProcessEventLog.md)
- [ProcessOutputData](docs/ProcessOutputData.md)
- [Require](docs/Require.md)
- [Variable](docs/Variable.md)


Expand Down
51 changes: 49 additions & 2 deletions api/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -201,9 +201,9 @@ paths:
summary: Get pipeline
tags:
- Pipeline
/pipeline/{pipeline_name}/cmd:
/pipeline/{pipeline_name}/command:
post:
operationId: pipeline_cmd
operationId: pipeline_command
parameters:
- description: The name of the pipeline
explode: false
Expand Down Expand Up @@ -925,6 +925,13 @@ components:
required:
- command
type: object
FlowpipeRequire:
example:
min_version: min_version
properties:
min_version:
type: string
type: object
FpPipeline:
example:
outputs:
Expand Down Expand Up @@ -1226,6 +1233,14 @@ components:
documentation: documentation
name: name
description: description
require:
mods:
- name: name
version: version
- name: name
version: version
flowpipe:
min_version: min_version
categories:
- categories
- categories
Expand All @@ -1248,9 +1263,22 @@ components:
type: string
opengraph:
$ref: '#/components/schemas/OpenGraph'
require:
$ref: '#/components/schemas/Require'
title:
type: string
type: object
ModVersionConstraint:
example:
name: name
version: version
properties:
name:
description: "the fully qualified mod name, e.g. github.com/turbot/mod1"
type: string
version:
type: string
type: object
OpenGraph:
example:
description: description
Expand Down Expand Up @@ -1309,6 +1337,23 @@ components:
process_id:
type: string
type: object
Require:
example:
mods:
- name: name
version: version
- name: name
version: version
flowpipe:
min_version: min_version
properties:
flowpipe:
$ref: '#/components/schemas/FlowpipeRequire'
mods:
items:
$ref: '#/components/schemas/ModVersionConstraint'
type: array
type: object
Variable:
example:
default: "{}"
Expand Down Expand Up @@ -1937,6 +1982,8 @@ components:
items:
$ref: '#/components/schemas/modconfig.StepError'
type: array
failure_mode:
type: string
status:
type: string
type: object
Expand Down
22 changes: 11 additions & 11 deletions api_pipeline.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 26 additions & 0 deletions docs/ExecutionStepExecutionOutput.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Data** | Pointer to **map[string]interface{}** | | [optional]
**Errors** | Pointer to [**[]ModconfigStepError**](ModconfigStepError.md) | | [optional]
**FailureMode** | Pointer to **string** | | [optional]
**Status** | Pointer to **string** | | [optional]

## Methods
Expand Down Expand Up @@ -77,6 +78,31 @@ SetErrors sets Errors field to given value.

HasErrors returns a boolean if a field has been set.

### GetFailureMode

`func (o *ExecutionStepExecutionOutput) GetFailureMode() string`

GetFailureMode returns the FailureMode field if non-nil, zero value otherwise.

### GetFailureModeOk

`func (o *ExecutionStepExecutionOutput) GetFailureModeOk() (*string, bool)`

GetFailureModeOk returns a tuple with the FailureMode field if it's non-nil, zero value otherwise
and a boolean to check if the value has been set.

### SetFailureMode

`func (o *ExecutionStepExecutionOutput) SetFailureMode(v string)`

SetFailureMode sets FailureMode field to given value.

### HasFailureMode

`func (o *ExecutionStepExecutionOutput) HasFailureMode() bool`

HasFailureMode returns a boolean if a field has been set.

### GetStatus

`func (o *ExecutionStepExecutionOutput) GetStatus() string`
Expand Down
56 changes: 56 additions & 0 deletions docs/FlowpipeRequire.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# FlowpipeRequire

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**MinVersion** | Pointer to **string** | | [optional]

## Methods

### NewFlowpipeRequire

`func NewFlowpipeRequire() *FlowpipeRequire`

NewFlowpipeRequire instantiates a new FlowpipeRequire object
This constructor will assign default values to properties that have it defined,
and makes sure properties required by API are set, but the set of arguments
will change when the set of required properties is changed

### NewFlowpipeRequireWithDefaults

`func NewFlowpipeRequireWithDefaults() *FlowpipeRequire`

NewFlowpipeRequireWithDefaults instantiates a new FlowpipeRequire object
This constructor will only assign default values to properties that have it defined,
but it doesn't guarantee that properties required by API are set

### GetMinVersion

`func (o *FlowpipeRequire) GetMinVersion() string`

GetMinVersion returns the MinVersion field if non-nil, zero value otherwise.

### GetMinVersionOk

`func (o *FlowpipeRequire) GetMinVersionOk() (*string, bool)`

GetMinVersionOk returns a tuple with the MinVersion field if it's non-nil, zero value otherwise
and a boolean to check if the value has been set.

### SetMinVersion

`func (o *FlowpipeRequire) SetMinVersion(v string)`

SetMinVersion sets MinVersion field to given value.

### HasMinVersion

`func (o *FlowpipeRequire) HasMinVersion() bool`

HasMinVersion returns a boolean if a field has been set.


[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


26 changes: 26 additions & 0 deletions docs/Mod.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Name | Type | Description | Notes
**Documentation** | Pointer to **string** | | [optional]
**Name** | Pointer to **string** | | [optional]
**Opengraph** | Pointer to [**OpenGraph**](OpenGraph.md) | | [optional]
**Require** | Pointer to [**Require**](Require.md) | | [optional]
**Title** | Pointer to **string** | | [optional]

## Methods
Expand Down Expand Up @@ -181,6 +182,31 @@ SetOpengraph sets Opengraph field to given value.

HasOpengraph returns a boolean if a field has been set.

### GetRequire

`func (o *Mod) GetRequire() Require`

GetRequire returns the Require field if non-nil, zero value otherwise.

### GetRequireOk

`func (o *Mod) GetRequireOk() (*Require, bool)`

GetRequireOk returns a tuple with the Require field if it's non-nil, zero value otherwise
and a boolean to check if the value has been set.

### SetRequire

`func (o *Mod) SetRequire(v Require)`

SetRequire sets Require field to given value.

### HasRequire

`func (o *Mod) HasRequire() bool`

HasRequire returns a boolean if a field has been set.

### GetTitle

`func (o *Mod) GetTitle() string`
Expand Down
Loading

0 comments on commit 2344d12

Please sign in to comment.