Skip to content

Commit

Permalink
ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.405.6
Browse files Browse the repository at this point in the history
  • Loading branch information
speakeasybot authored and unclesp1d3r committed Oct 2, 2024
1 parent bc38f00 commit a317a1a
Show file tree
Hide file tree
Showing 19 changed files with 103 additions and 106 deletions.
32 changes: 16 additions & 16 deletions .speakeasy/gen.lock
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
lockVersion: 2.0.0
id: 11fa8266-8454-49fd-ba7b-d5f8744980cc
management:
docChecksum: c77abf90c6133eb42b34c8f1cebf6a14
docChecksum: 80bec64634a58ec3b0bd964a9c6c93aa
docVersion: "1.3"
speakeasyVersion: 1.400.1
generationVersion: 2.420.2
releaseVersion: 0.8.4
configChecksum: cf0336461325480916f9ea69c9b17c8c
speakeasyVersion: 1.405.6
generationVersion: 2.428.1
releaseVersion: 0.8.5
configChecksum: da8775756c935932081875da2f426f58
repoURL: https://github.com/unclesp1d3r/cipherswarm-agent-sdk-go.git
installationURL: https://github.com/unclesp1d3r/cipherswarm-agent-sdk-go
features:
go:
additionalDependencies: 0.1.0
constsAndDefaults: 0.1.6
core: 3.5.9
core: 3.5.12
defaultEnabledRetries: 0.2.0
downloadStreams: 0.1.2
envVarSecurityUsage: 0.3.1
Expand Down Expand Up @@ -166,7 +166,7 @@ examples:
id: 135003
responses:
"200":
application/json: {"id": 94, "name": "ratke-bode", "client_signature": "Linux, ArchLinux 2022.08.05", "state": "pending", "operating_system": "linux", "devices": ["cpu", "GPU"], "advanced_configuration": {"agent_update_interval": 46, "use_native_hashcat": false, "backend_device": null, "opencl_devices": null, "enable_additional_hash_types": false}}
application/json: {"id": 2571, "host_name": "weissnat", "client_signature": "macOS, High Sierra (10.13)", "state": "active", "operating_system": "linux", "devices": ["cpu", "GPU"], "advanced_configuration": {"agent_update_interval": 36, "use_native_hashcat": false, "backend_device": null, "opencl_devices": null, "enable_additional_hash_types": false}}
"401":
application/json: {"error": "Bad credentials"}
updateAgent:
Expand All @@ -175,18 +175,18 @@ examples:
path:
id: 828119
requestBody:
application/json: {"id": 96, "name": "effertz-frami", "client_signature": "Plan 9, Plan 9 Fourth Edition", "operating_system": "linux", "devices": ["cpu", "GPU"]}
application/json: {"id": 2573, "host_name": "stoltenberg", "client_signature": "Linux, RHEL 6.10", "operating_system": "linux", "devices": ["cpu", "GPU"]}
responses:
"200":
application/json: {"id": 912003, "name": "<value>", "client_signature": "<value>", "state": "error", "operating_system": "<value>", "devices": ["<value>", "<value>", "<value>"], "advanced_configuration": {"agent_update_interval": 666222, "use_native_hashcat": true, "backend_device": "<value>", "enable_additional_hash_types": false}}
application/json: {"id": 912003, "host_name": "surprised-thyme.net", "client_signature": "<value>", "state": "error", "operating_system": "<value>", "devices": ["<value>", "<value>", "<value>"], "advanced_configuration": {"agent_update_interval": 666222, "use_native_hashcat": true, "backend_device": "<value>", "enable_additional_hash_types": false}}
"401": {}
test_example:
parameters:
path:
id: 182255
responses:
"200":
application/json: {"id": 96, "name": "effertz-frami", "client_signature": "Plan 9, Plan 9 Fourth Edition", "state": "pending", "operating_system": "linux", "devices": ["cpu", "GPU"], "advanced_configuration": {"agent_update_interval": 42, "use_native_hashcat": false, "backend_device": null, "opencl_devices": null, "enable_additional_hash_types": false}}
application/json: {"id": 2573, "host_name": "stoltenberg", "client_signature": "Linux, RHEL 6.10", "state": "active", "operating_system": "linux", "devices": ["cpu", "GPU"], "advanced_configuration": {"agent_update_interval": 24, "use_native_hashcat": false, "backend_device": null, "opencl_devices": null, "enable_additional_hash_types": false}}
"401":
application/json: {"error": "Bad credentials"}
sendHeartbeat:
Expand Down Expand Up @@ -232,7 +232,7 @@ examples:
id: 535539
responses:
"200":
application/json: {"id": 47, "attack_mode": "dictionary", "attack_mode_hashcat": 0, "mask": "", "increment_mode": false, "increment_minimum": 0, "increment_maximum": 0, "optimized": true, "slow_candidate_generators": false, "workload_profile": 3, "disable_markov": false, "classic_markov": false, "markov_threshold": 0, "left_rule": "", "right_rule": "", "custom_charset_1": "", "custom_charset_2": "", "custom_charset_3": "", "custom_charset_4": "", "hash_list_id": 64, "word_list": {"id": 54, "download_url": "http://www.example.com/rails/active_storage/blobs/redirect/eyJfcmFpbHMiOnsiZGF0YSI6MTQwLCJwdXIiOiJibG9iX2lkIn19--9b15f11a378659093028a10c5635001456dbec0e/top-passwords.txt", "checksum": "vL58BUq0+tAQjqHwejEh8A==", "file_name": "top-passwords.txt"}, "rule_list": null, "mask_list": null, "hash_mode": 0, "hash_list_url": "http://www.example.com/api/v1/client/attacks/47/hash_list", "hash_list_checksum": "1B2M2Y8AsgTpgAmY7PhCfg==", "url": "http://www.example.com/campaigns/47/attacks/47.json"}
application/json: {"id": 1000, "attack_mode": "dictionary", "attack_mode_hashcat": 0, "mask": "", "increment_mode": false, "increment_minimum": 0, "increment_maximum": 0, "optimized": true, "slow_candidate_generators": false, "workload_profile": 3, "disable_markov": false, "classic_markov": false, "markov_threshold": 0, "left_rule": "", "right_rule": "", "custom_charset_1": "", "custom_charset_2": "", "custom_charset_3": "", "custom_charset_4": "", "hash_list_id": 1807, "word_list": {"id": 2560, "download_url": "http://www.example.com/rails/active_storage/blobs/redirect/eyJfcmFpbHMiOnsiZGF0YSI6NzcxMiwicHVyIjoiYmxvYl9pZCJ9fQ==--9584213bf1b3bcc2b08814da1a2ccbcec5d76f09/top-passwords.txt", "checksum": "vL58BUq0+tAQjqHwejEh8A==", "file_name": "top-passwords.txt"}, "rule_list": null, "mask_list": null, "hash_mode": 0, "hash_list_url": "http://www.example.com/api/v1/client/attacks/1000/hash_list", "hash_list_checksum": "1B2M2Y8AsgTpgAmY7PhCfg==", "url": "http://www.example.com/campaigns/1000/attacks/1000.json"}
"401":
application/json: {"error": "Attack not found."}
getHashList:
Expand All @@ -254,7 +254,7 @@ examples:
test_example:
responses:
"200":
application/json: {"id": 50, "attack_id": 50, "start_date": "2024-08-25T21:36:03.829-04:00", "status": "pending", "skip": 0, "limit": 0}
application/json: {"id": 802, "attack_id": 1003, "start_date": "2024-10-01T21:16:42.896-04:00", "status": "pending", "skip": 0, "limit": 0}
"401":
application/json: {"error": "Bad credentials"}
getTask:
Expand All @@ -264,7 +264,7 @@ examples:
id: 771489
responses:
"200":
application/json: {"id": 51, "attack_id": 51, "start_date": "2024-08-24T23:09:45.984-04:00", "status": "pending", "skip": 0, "limit": 0}
application/json: {"id": 803, "attack_id": 1004, "start_date": "2024-10-01T09:13:42.205-04:00", "status": "pending", "skip": 0, "limit": 0}
"401":
application/json: {"error": "Record not found"}
sendCrack:
Expand All @@ -273,7 +273,7 @@ examples:
path:
id: 302642
requestBody:
application/json: {"timestamp": "2024-08-25T21:36:04.134-04:00", "hash": "dummy_hash_2", "plain_text": "dummy_plain"}
application/json: {"timestamp": "2024-10-01T21:16:43.171-04:00", "hash": "dummy_hash_2", "plain_text": "dummy_plain"}
test_example:
parameters:
path:
Expand Down Expand Up @@ -329,13 +329,13 @@ examples:
test_example:
responses:
"200":
application/json: {"config": {"agent_update_interval": 52, "use_native_hashcat": false, "backend_device": null, "opencl_devices": null, "enable_additional_hash_types": false}, "api_version": 1}
application/json: {"config": {"agent_update_interval": 49, "use_native_hashcat": false, "backend_device": null, "opencl_devices": null, "enable_additional_hash_types": false}, "api_version": 1}
"401":
application/json: {"error": "Bad credentials"}
authenticate:
test_example:
responses:
"200":
application/json: {"authenticated": true, "agent_id": 148}
application/json: {"authenticated": true, "agent_id": 2624}
"401":
application/json: {"error": "Bad credentials"}
2 changes: 1 addition & 1 deletion .speakeasy/gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ generation:
auth:
oAuth2ClientCredentialsEnabled: false
go:
version: 0.8.4
version: 0.8.5
additionalDependencies: {}
allowUnknownFieldsInWeakUnions: false
clientServerStatusCodesAsErrors: true
Expand Down
10 changes: 5 additions & 5 deletions .speakeasy/workflow.lock
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
speakeasyVersion: 1.400.1
speakeasyVersion: 1.405.6
sources:
CipherSwarm_agent_api:
sourceNamespace: cipher-swarm-agent-api
sourceRevisionDigest: sha256:f9787ad737cfb6a94a7230bcfabc8f5edd188432525efd4b67ddc7bb8f1a0e2e
sourceBlobDigest: sha256:93c3f31880777a5d06b7df353d9dffb8066729999e96794680edd65284d8c216
sourceRevisionDigest: sha256:6177f29fa2a1b6650a8cc068e7c18805e5357b578c9642bcd555ccb1d6a425a3
sourceBlobDigest: sha256:da9d36e24d7d4937a832076a8683c8b680020db5ade075e05a5cd0931ce380f5
tags:
- latest
- main
targets:
golang-sdk:
source: CipherSwarm_agent_api
sourceNamespace: cipher-swarm-agent-api
sourceRevisionDigest: sha256:f9787ad737cfb6a94a7230bcfabc8f5edd188432525efd4b67ddc7bb8f1a0e2e
sourceBlobDigest: sha256:93c3f31880777a5d06b7df353d9dffb8066729999e96794680edd65284d8c216
sourceRevisionDigest: sha256:6177f29fa2a1b6650a8cc068e7c18805e5357b578c9642bcd555ccb1d6a425a3
sourceBlobDigest: sha256:da9d36e24d7d4937a832076a8683c8b680020db5ade075e05a5cd0931ce380f5
workflow:
workflowVersion: 1.0.0
speakeasyVersion: latest
Expand Down
10 changes: 7 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,12 +128,16 @@ func main() {
<!-- Start Error Handling [errors] -->
## Error Handling

Handling errors in this SDK should largely match your expectations. All operations return a response object or an error, they will never return both. When specified by the OpenAPI spec document, the SDK will return the appropriate subclass.
Handling errors in this SDK should largely match your expectations. All operations return a response object or an error, they will never return both.

| Error Object | Status Code | Content Type |
By Default, an API error will return `sdkerrors.SDKError`. When custom error responses are specified for an operation, the SDK may also return their associated error. You can refer to respective *Errors* tables in SDK docs for more details on possible error types for each operation.

For example, the `GetAgent` function may return the following errors:

| Error Type | Status Code | Content Type |
| --------------------- | --------------------- | --------------------- |
| sdkerrors.ErrorObject | 401 | application/json |
| sdkerrors.SDKError | 4xx-5xx | */* |
| sdkerrors.SDKError | 4XX, 5XX | \*/\* |

### Example

Expand Down
12 changes: 11 additions & 1 deletion RELEASES.md
Original file line number Diff line number Diff line change
Expand Up @@ -278,4 +278,14 @@ Based on:
### Generated
- [go v0.8.4] .
### Releases
- [Go v0.8.4] https://github.com/unclesp1d3r/cipherswarm-agent-sdk-go/releases/tag/v0.8.4 - .
- [Go v0.8.4] https://github.com/unclesp1d3r/cipherswarm-agent-sdk-go/releases/tag/v0.8.4 - .

## 2024-10-02 03:01:05
### Changes
Based on:
- OpenAPI Doc
- Speakeasy CLI 1.405.6 (2.428.1) https://github.com/speakeasy-api/speakeasy
### Generated
- [go v0.8.5] .
### Releases
- [Go v0.8.5] https://github.com/unclesp1d3r/cipherswarm-agent-sdk-go/releases/tag/v0.8.5 - .
6 changes: 3 additions & 3 deletions cipherswarmagentsdk.go
Original file line number Diff line number Diff line change
Expand Up @@ -200,9 +200,9 @@ func New(opts ...SDKOption) *CipherSwarmAgentSDK {
sdkConfiguration: sdkConfiguration{
Language: "go",
OpenAPIDocVersion: "1.3",
SDKVersion: "0.8.4",
GenVersion: "2.420.2",
UserAgent: "speakeasy-sdk/go 0.8.4 2.420.2 1.3 github.com/unclesp1d3r/cipherswarm-agent-sdk-go",
SDKVersion: "0.8.5",
GenVersion: "2.428.1",
UserAgent: "speakeasy-sdk/go 0.8.5 2.428.1 1.3 github.com/unclesp1d3r/cipherswarm-agent-sdk-go",
ServerDefaults: []map[string]string{
{
"defaultHost": "www.example.com",
Expand Down
2 changes: 1 addition & 1 deletion docs/models/components/agent.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
| Field | Type | Required | Description |
| ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- |
| `ID` | *int64* | :heavy_check_mark: | The id of the agent |
| `Name` | *string* | :heavy_check_mark: | The hostname of the agent |
| `HostName` | *string* | :heavy_check_mark: | The hostname of the agent |
| `ClientSignature` | *string* | :heavy_check_mark: | The signature of the client |
| `State` | [components.State](../../models/components/state.md) | :heavy_check_mark: | The state of the agent |
| `OperatingSystem` | *string* | :heavy_check_mark: | The operating system of the agent |
Expand Down
2 changes: 1 addition & 1 deletion docs/models/operations/updateagentrequestbody.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
| Field | Type | Required | Description |
| --------------------------------- | --------------------------------- | --------------------------------- | --------------------------------- |
| `ID` | *int64* | :heavy_check_mark: | The id of the agent |
| `Name` | *string* | :heavy_check_mark: | The hostname of the agent |
| `HostName` | *string* | :heavy_check_mark: | The hostname of the agent |
| `ClientSignature` | *string* | :heavy_check_mark: | The signature of the client |
| `OperatingSystem` | *string* | :heavy_check_mark: | The operating system of the agent |
| `Devices` | []*string* | :heavy_check_mark: | N/A |
2 changes: 0 additions & 2 deletions docs/models/sdkerrors/errorobject.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# ErrorObject

Not authorized


## Fields

Expand Down
37 changes: 16 additions & 21 deletions docs/sdks/agents/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,10 @@ func main() {

### Errors

| Error Object | Status Code | Content Type |
| Error Type | Status Code | Content Type |
| --------------------- | --------------------- | --------------------- |
| sdkerrors.ErrorObject | 401 | application/json |
| sdkerrors.SDKError | 4xx-5xx | */* |

| sdkerrors.SDKError | 4XX, 5XX | \*/\* |

## UpdateAgent

Expand All @@ -88,9 +87,9 @@ func main() {

ctx := context.Background()
res, err := s.Agents.UpdateAgent(ctx, 828119, &operations.UpdateAgentRequestBody{
ID: 96,
Name: "effertz-frami",
ClientSignature: "Plan 9, Plan 9 Fourth Edition",
ID: 2573,
HostName: "stoltenberg",
ClientSignature: "Linux, RHEL 6.10",
OperatingSystem: "linux",
Devices: []string{
"cpu",
Expand Down Expand Up @@ -121,11 +120,10 @@ func main() {

### Errors

| Error Object | Status Code | Content Type |
| Error Type | Status Code | Content Type |
| --------------------- | --------------------- | --------------------- |
| sdkerrors.ErrorObject | 401 | application/json |
| sdkerrors.SDKError | 4xx-5xx | */* |

| sdkerrors.SDKError | 4XX, 5XX | \*/\* |

## SendHeartbeat

Expand Down Expand Up @@ -172,11 +170,10 @@ func main() {

### Errors

| Error Object | Status Code | Content Type |
| Error Type | Status Code | Content Type |
| --------------------- | --------------------- | --------------------- |
| sdkerrors.ErrorObject | 401 | application/json |
| sdkerrors.SDKError | 4xx-5xx | */* |

| sdkerrors.SDKError | 4XX, 5XX | \*/\* |

## SubmitBenchmark

Expand Down Expand Up @@ -235,11 +232,10 @@ func main() {

### Errors

| Error Object | Status Code | Content Type |
| Error Type | Status Code | Content Type |
| --------------------- | --------------------- | --------------------- |
| sdkerrors.ErrorObject | 400,401 | application/json |
| sdkerrors.SDKError | 4xx-5xx | */* |

| sdkerrors.ErrorObject | 400, 401 | application/json |
| sdkerrors.SDKError | 4XX, 5XX | \*/\* |

## SubmitErrorAgent

Expand Down Expand Up @@ -287,11 +283,10 @@ func main() {

### Errors

| Error Object | Status Code | Content Type |
| Error Type | Status Code | Content Type |
| --------------------- | --------------------- | --------------------- |
| sdkerrors.ErrorObject | 401 | application/json |
| sdkerrors.SDKError | 4xx-5xx | */* |

| sdkerrors.SDKError | 4XX, 5XX | \*/\* |

## SetAgentShutdown

Expand Down Expand Up @@ -338,7 +333,7 @@ func main() {

### Errors

| Error Object | Status Code | Content Type |
| Error Type | Status Code | Content Type |
| --------------------- | --------------------- | --------------------- |
| sdkerrors.ErrorObject | 401 | application/json |
| sdkerrors.SDKError | 4xx-5xx | */* |
| sdkerrors.SDKError | 4XX, 5XX | \*/\* |
Loading

0 comments on commit a317a1a

Please sign in to comment.