zavudev 0.10.0 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +8 -0
- data/README.md +1 -1
- data/lib/zavudev/client.rb +8 -0
- data/lib/zavudev/models/contact_delete_params.rb +20 -0
- data/lib/zavudev/models/function_create_params.rb +104 -0
- data/lib/zavudev/models/function_create_response.rb +168 -0
- data/lib/zavudev/models/function_delete_params.rb +20 -0
- data/lib/zavudev/models/function_delete_response.rb +28 -0
- data/lib/zavudev/models/function_deploy_params.rb +37 -0
- data/lib/zavudev/models/function_deploy_response.rb +104 -0
- data/lib/zavudev/models/function_get_deployment_params.rb +20 -0
- data/lib/zavudev/models/function_get_deployment_response.rb +104 -0
- data/lib/zavudev/models/function_retrieve_params.rb +20 -0
- data/lib/zavudev/models/function_retrieve_response.rb +168 -0
- data/lib/zavudev/models/function_tail_logs_params.rb +58 -0
- data/lib/zavudev/models/function_tail_logs_response.rb +41 -0
- data/lib/zavudev/models/function_update_params.rb +37 -0
- data/lib/zavudev/models/function_update_response.rb +168 -0
- data/lib/zavudev/models/functions/secret_list_params.rb +22 -0
- data/lib/zavudev/models/functions/secret_list_response.rb +59 -0
- data/lib/zavudev/models/functions/secret_set_params.rb +34 -0
- data/lib/zavudev/models/functions/secret_set_response.rb +10 -0
- data/lib/zavudev/models/functions/secret_unset_params.rb +28 -0
- data/lib/zavudev/models/me_retrieve_params.rb +14 -0
- data/lib/zavudev/models/me_retrieve_response.rb +85 -0
- data/lib/zavudev/models/message_show_typing_params.rb +26 -0
- data/lib/zavudev/models/message_show_typing_response.rb +16 -0
- data/lib/zavudev/models/senders/agent/execution_retrieve_params.rb +30 -0
- data/lib/zavudev/models/senders/agent/execution_retrieve_response.rb +20 -0
- data/lib/zavudev/models.rb +22 -0
- data/lib/zavudev/resources/contacts.rb +24 -0
- data/lib/zavudev/resources/functions/secrets.rb +98 -0
- data/lib/zavudev/resources/functions.rb +220 -0
- data/lib/zavudev/resources/me.rb +33 -0
- data/lib/zavudev/resources/messages.rb +31 -0
- data/lib/zavudev/resources/senders/agent/executions.rb +26 -0
- data/lib/zavudev/version.rb +1 -1
- data/lib/zavudev.rb +29 -0
- data/rbi/zavudev/client.rbi +6 -0
- data/rbi/zavudev/models/contact_delete_params.rbi +35 -0
- data/rbi/zavudev/models/function_create_params.rbi +177 -0
- data/rbi/zavudev/models/function_create_response.rbi +277 -0
- data/rbi/zavudev/models/function_delete_params.rbi +35 -0
- data/rbi/zavudev/models/function_delete_response.rbi +44 -0
- data/rbi/zavudev/models/function_deploy_params.rbi +63 -0
- data/rbi/zavudev/models/function_deploy_response.rbi +196 -0
- data/rbi/zavudev/models/function_get_deployment_params.rbi +38 -0
- data/rbi/zavudev/models/function_get_deployment_response.rbi +201 -0
- data/rbi/zavudev/models/function_retrieve_params.rbi +35 -0
- data/rbi/zavudev/models/function_retrieve_response.rbi +277 -0
- data/rbi/zavudev/models/function_tail_logs_params.rbi +90 -0
- data/rbi/zavudev/models/function_tail_logs_response.rbi +75 -0
- data/rbi/zavudev/models/function_update_params.rbi +63 -0
- data/rbi/zavudev/models/function_update_response.rbi +277 -0
- data/rbi/zavudev/models/functions/secret_list_params.rbi +40 -0
- data/rbi/zavudev/models/functions/secret_list_response.rbi +118 -0
- data/rbi/zavudev/models/functions/secret_set_params.rbi +53 -0
- data/rbi/zavudev/models/functions/secret_set_response.rbi +9 -0
- data/rbi/zavudev/models/functions/secret_unset_params.rbi +48 -0
- data/rbi/zavudev/models/me_retrieve_params.rbi +27 -0
- data/rbi/zavudev/models/me_retrieve_response.rbi +151 -0
- data/rbi/zavudev/models/message_show_typing_params.rbi +46 -0
- data/rbi/zavudev/models/message_show_typing_response.rbi +26 -0
- data/rbi/zavudev/models/senders/agent/execution_retrieve_params.rbi +50 -0
- data/rbi/zavudev/models/senders/agent/execution_retrieve_response.rbi +41 -0
- data/rbi/zavudev/models.rbi +22 -0
- data/rbi/zavudev/resources/contacts.rbi +15 -0
- data/rbi/zavudev/resources/functions/secrets.rbi +69 -0
- data/rbi/zavudev/resources/functions.rbi +171 -0
- data/rbi/zavudev/resources/me.rbi +22 -0
- data/rbi/zavudev/resources/messages.rbi +21 -0
- data/rbi/zavudev/resources/senders/agent/executions.rbi +14 -0
- data/sig/zavudev/client.rbs +4 -0
- data/sig/zavudev/models/contact_delete_params.rbs +23 -0
- data/sig/zavudev/models/function_create_params.rbs +107 -0
- data/sig/zavudev/models/function_create_response.rbs +126 -0
- data/sig/zavudev/models/function_delete_params.rbs +23 -0
- data/sig/zavudev/models/function_delete_response.rbs +22 -0
- data/sig/zavudev/models/function_deploy_params.rbs +40 -0
- data/sig/zavudev/models/function_deploy_response.rbs +98 -0
- data/sig/zavudev/models/function_get_deployment_params.rbs +23 -0
- data/sig/zavudev/models/function_get_deployment_response.rbs +98 -0
- data/sig/zavudev/models/function_retrieve_params.rbs +23 -0
- data/sig/zavudev/models/function_retrieve_response.rbs +126 -0
- data/sig/zavudev/models/function_tail_logs_params.rbs +61 -0
- data/sig/zavudev/models/function_tail_logs_response.rbs +37 -0
- data/sig/zavudev/models/function_update_params.rbs +40 -0
- data/sig/zavudev/models/function_update_response.rbs +126 -0
- data/sig/zavudev/models/functions/secret_list_params.rbs +25 -0
- data/sig/zavudev/models/functions/secret_list_response.rbs +70 -0
- data/sig/zavudev/models/functions/secret_set_params.rbs +34 -0
- data/sig/zavudev/models/functions/secret_set_response.rbs +7 -0
- data/sig/zavudev/models/functions/secret_unset_params.rbs +30 -0
- data/sig/zavudev/models/me_retrieve_params.rbs +14 -0
- data/sig/zavudev/models/me_retrieve_response.rbs +75 -0
- data/sig/zavudev/models/message_show_typing_params.rbs +30 -0
- data/sig/zavudev/models/message_show_typing_response.rbs +13 -0
- data/sig/zavudev/models/senders/agent/execution_retrieve_params.rbs +32 -0
- data/sig/zavudev/models/senders/agent/execution_retrieve_response.rbs +18 -0
- data/sig/zavudev/models.rbs +22 -0
- data/sig/zavudev/resources/contacts.rbs +5 -0
- data/sig/zavudev/resources/functions/secrets.rbs +27 -0
- data/sig/zavudev/resources/functions.rbs +61 -0
- data/sig/zavudev/resources/me.rbs +11 -0
- data/sig/zavudev/resources/messages.rbs +6 -0
- data/sig/zavudev/resources/senders/agent/executions.rbs +6 -0
- metadata +88 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 31fc9cb2bdd57145a425db99ba4a661bee75e90ba40c1e7cc67a162739fe37f9
|
|
4
|
+
data.tar.gz: eb9e7b3ddd8cb6470d9c3b34f5bf9a53ca8692ae45e4fd36d3c9d328b180e8dd
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1242a227dd76d5a43f68581b50f92844963e81b8f392a1e71f613cad7c88f98a1c3b43fc63c1fc130ac23ac9bf7d740d8c0243be6e0ca7292545f6e76ff51942
|
|
7
|
+
data.tar.gz: ca5d5b577c6210261dd24cae7d95466451134cb4a23e1b71648d64f83fa96ea684b99897afd94138e3d1644e0e425d0d9f7cc59aed7899175aa5a36df7ce3b27
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.11.0 (2026-05-25)
|
|
4
|
+
|
|
5
|
+
Full Changelog: [v0.10.0...v0.11.0](https://github.com/zavudev/sdk-ruby/compare/v0.10.0...v0.11.0)
|
|
6
|
+
|
|
7
|
+
### Features
|
|
8
|
+
|
|
9
|
+
* **api:** manual updates ([db0beb6](https://github.com/zavudev/sdk-ruby/commit/db0beb6315828cbec3bb816e77abb3231a792e88))
|
|
10
|
+
|
|
3
11
|
## 0.10.0 (2026-05-25)
|
|
4
12
|
|
|
5
13
|
Full Changelog: [v0.9.1...v0.10.0](https://github.com/zavudev/sdk-ruby/compare/v0.9.1...v0.10.0)
|
data/README.md
CHANGED
data/lib/zavudev/client.rb
CHANGED
|
@@ -69,6 +69,12 @@ module Zavudev
|
|
|
69
69
|
# @return [Zavudev::Resources::Number10dlc]
|
|
70
70
|
attr_reader :number_10dlc
|
|
71
71
|
|
|
72
|
+
# @return [Zavudev::Resources::Me]
|
|
73
|
+
attr_reader :me
|
|
74
|
+
|
|
75
|
+
# @return [Zavudev::Resources::Functions]
|
|
76
|
+
attr_reader :functions
|
|
77
|
+
|
|
72
78
|
# @api private
|
|
73
79
|
#
|
|
74
80
|
# @return [Hash{String=>String}]
|
|
@@ -147,6 +153,8 @@ module Zavudev
|
|
|
147
153
|
@usage = Zavudev::Resources::Usage.new(client: self)
|
|
148
154
|
@sub_accounts = Zavudev::Resources::SubAccounts.new(client: self)
|
|
149
155
|
@number_10dlc = Zavudev::Resources::Number10dlc.new(client: self)
|
|
156
|
+
@me = Zavudev::Resources::Me.new(client: self)
|
|
157
|
+
@functions = Zavudev::Resources::Functions.new(client: self)
|
|
150
158
|
end
|
|
151
159
|
end
|
|
152
160
|
end
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Zavudev
|
|
4
|
+
module Models
|
|
5
|
+
# @see Zavudev::Resources::Contacts#delete
|
|
6
|
+
class ContactDeleteParams < Zavudev::Internal::Type::BaseModel
|
|
7
|
+
extend Zavudev::Internal::Type::RequestParameters::Converter
|
|
8
|
+
include Zavudev::Internal::Type::RequestParameters
|
|
9
|
+
|
|
10
|
+
# @!attribute contact_id
|
|
11
|
+
#
|
|
12
|
+
# @return [String]
|
|
13
|
+
required :contact_id, String
|
|
14
|
+
|
|
15
|
+
# @!method initialize(contact_id:, request_options: {})
|
|
16
|
+
# @param contact_id [String]
|
|
17
|
+
# @param request_options [Zavudev::RequestOptions, Hash{Symbol=>Object}]
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
end
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Zavudev
|
|
4
|
+
module Models
|
|
5
|
+
# @see Zavudev::Resources::Functions#create
|
|
6
|
+
class FunctionCreateParams < Zavudev::Internal::Type::BaseModel
|
|
7
|
+
extend Zavudev::Internal::Type::RequestParameters::Converter
|
|
8
|
+
include Zavudev::Internal::Type::RequestParameters
|
|
9
|
+
|
|
10
|
+
# @!attribute name
|
|
11
|
+
#
|
|
12
|
+
# @return [String]
|
|
13
|
+
required :name, String
|
|
14
|
+
|
|
15
|
+
# @!attribute slug
|
|
16
|
+
# URL-safe identifier (lowercase, digits, hyphens). Must be unique per project.
|
|
17
|
+
#
|
|
18
|
+
# @return [String]
|
|
19
|
+
required :slug, String
|
|
20
|
+
|
|
21
|
+
# @!attribute dependencies
|
|
22
|
+
# npm dependencies. Keys are package names, values are semver ranges.
|
|
23
|
+
#
|
|
24
|
+
# @return [Hash{Symbol=>String}, nil]
|
|
25
|
+
optional :dependencies, Zavudev::Internal::Type::HashOf[String]
|
|
26
|
+
|
|
27
|
+
# @!attribute description
|
|
28
|
+
#
|
|
29
|
+
# @return [String, nil]
|
|
30
|
+
optional :description, String
|
|
31
|
+
|
|
32
|
+
# @!attribute http_enabled
|
|
33
|
+
# Whether to expose a public HTTPS URL for this function.
|
|
34
|
+
#
|
|
35
|
+
# @return [Boolean, nil]
|
|
36
|
+
optional :http_enabled, Zavudev::Internal::Type::Boolean, api_name: :httpEnabled
|
|
37
|
+
|
|
38
|
+
# @!attribute memory_mb
|
|
39
|
+
#
|
|
40
|
+
# @return [Integer, Zavudev::Models::FunctionCreateParams::MemoryMB, nil]
|
|
41
|
+
optional :memory_mb, enum: -> { Zavudev::FunctionCreateParams::MemoryMB }, api_name: :memoryMb
|
|
42
|
+
|
|
43
|
+
# @!attribute runtime
|
|
44
|
+
# Runtime the function is deployed on.
|
|
45
|
+
#
|
|
46
|
+
# @return [Symbol, Zavudev::Models::FunctionCreateParams::Runtime, nil]
|
|
47
|
+
optional :runtime, enum: -> { Zavudev::FunctionCreateParams::Runtime }
|
|
48
|
+
|
|
49
|
+
# @!attribute source_code
|
|
50
|
+
# TypeScript source code for the function entry point (max ~900KB).
|
|
51
|
+
#
|
|
52
|
+
# @return [String, nil]
|
|
53
|
+
optional :source_code, String, api_name: :sourceCode
|
|
54
|
+
|
|
55
|
+
# @!attribute timeout_sec
|
|
56
|
+
#
|
|
57
|
+
# @return [Integer, nil]
|
|
58
|
+
optional :timeout_sec, Integer, api_name: :timeoutSec
|
|
59
|
+
|
|
60
|
+
# @!method initialize(name:, slug:, dependencies: nil, description: nil, http_enabled: nil, memory_mb: nil, runtime: nil, source_code: nil, timeout_sec: nil, request_options: {})
|
|
61
|
+
# @param name [String]
|
|
62
|
+
#
|
|
63
|
+
# @param slug [String] URL-safe identifier (lowercase, digits, hyphens). Must be unique per project.
|
|
64
|
+
#
|
|
65
|
+
# @param dependencies [Hash{Symbol=>String}] npm dependencies. Keys are package names, values are semver ranges.
|
|
66
|
+
#
|
|
67
|
+
# @param description [String]
|
|
68
|
+
#
|
|
69
|
+
# @param http_enabled [Boolean] Whether to expose a public HTTPS URL for this function.
|
|
70
|
+
#
|
|
71
|
+
# @param memory_mb [Integer, Zavudev::Models::FunctionCreateParams::MemoryMB]
|
|
72
|
+
#
|
|
73
|
+
# @param runtime [Symbol, Zavudev::Models::FunctionCreateParams::Runtime] Runtime the function is deployed on.
|
|
74
|
+
#
|
|
75
|
+
# @param source_code [String] TypeScript source code for the function entry point (max ~900KB).
|
|
76
|
+
#
|
|
77
|
+
# @param timeout_sec [Integer]
|
|
78
|
+
#
|
|
79
|
+
# @param request_options [Zavudev::RequestOptions, Hash{Symbol=>Object}]
|
|
80
|
+
|
|
81
|
+
module MemoryMB
|
|
82
|
+
extend Zavudev::Internal::Type::Enum
|
|
83
|
+
|
|
84
|
+
MEMORY_MB_128 = 128
|
|
85
|
+
MEMORY_MB_256 = 256
|
|
86
|
+
MEMORY_MB_512 = 512
|
|
87
|
+
MEMORY_MB_1024 = 1024
|
|
88
|
+
|
|
89
|
+
# @!method self.values
|
|
90
|
+
# @return [Array<Integer>]
|
|
91
|
+
end
|
|
92
|
+
|
|
93
|
+
# Runtime the function is deployed on.
|
|
94
|
+
module Runtime
|
|
95
|
+
extend Zavudev::Internal::Type::Enum
|
|
96
|
+
|
|
97
|
+
NODEJS24 = :nodejs24
|
|
98
|
+
|
|
99
|
+
# @!method self.values
|
|
100
|
+
# @return [Array<Symbol>]
|
|
101
|
+
end
|
|
102
|
+
end
|
|
103
|
+
end
|
|
104
|
+
end
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Zavudev
|
|
4
|
+
module Models
|
|
5
|
+
# @see Zavudev::Resources::Functions#create
|
|
6
|
+
class FunctionCreateResponse < Zavudev::Internal::Type::BaseModel
|
|
7
|
+
# @!attribute function
|
|
8
|
+
# A Zavu Function — user-supplied TypeScript that runs in Zavu Cloud and reacts to
|
|
9
|
+
# messaging events or HTTP requests.
|
|
10
|
+
#
|
|
11
|
+
# @return [Zavudev::Models::FunctionCreateResponse::Function]
|
|
12
|
+
required :function, -> { Zavudev::Models::FunctionCreateResponse::Function }
|
|
13
|
+
|
|
14
|
+
# @!method initialize(function:)
|
|
15
|
+
# Some parameter documentations has been truncated, see
|
|
16
|
+
# {Zavudev::Models::FunctionCreateResponse} for more details.
|
|
17
|
+
#
|
|
18
|
+
# @param function [Zavudev::Models::FunctionCreateResponse::Function] A Zavu Function — user-supplied TypeScript that runs in Zavu Cloud and reacts to
|
|
19
|
+
|
|
20
|
+
# @see Zavudev::Models::FunctionCreateResponse#function
|
|
21
|
+
class Function < Zavudev::Internal::Type::BaseModel
|
|
22
|
+
# @!attribute id
|
|
23
|
+
#
|
|
24
|
+
# @return [String]
|
|
25
|
+
required :id, String
|
|
26
|
+
|
|
27
|
+
# @!attribute created_at
|
|
28
|
+
#
|
|
29
|
+
# @return [Time]
|
|
30
|
+
required :created_at, Time, api_name: :createdAt
|
|
31
|
+
|
|
32
|
+
# @!attribute dependencies
|
|
33
|
+
# npm dependencies installed in the function bundle. Keys are package names,
|
|
34
|
+
# values are semver ranges.
|
|
35
|
+
#
|
|
36
|
+
# @return [Hash{Symbol=>String}]
|
|
37
|
+
required :dependencies, Zavudev::Internal::Type::HashOf[String]
|
|
38
|
+
|
|
39
|
+
# @!attribute http_enabled
|
|
40
|
+
# Whether the function can be invoked over HTTPS via its public URL.
|
|
41
|
+
#
|
|
42
|
+
# @return [Boolean]
|
|
43
|
+
required :http_enabled, Zavudev::Internal::Type::Boolean, api_name: :httpEnabled
|
|
44
|
+
|
|
45
|
+
# @!attribute memory_mb
|
|
46
|
+
# Memory allocation in MB.
|
|
47
|
+
#
|
|
48
|
+
# @return [Integer]
|
|
49
|
+
required :memory_mb, Integer, api_name: :memoryMb
|
|
50
|
+
|
|
51
|
+
# @!attribute name
|
|
52
|
+
#
|
|
53
|
+
# @return [String]
|
|
54
|
+
required :name, String
|
|
55
|
+
|
|
56
|
+
# @!attribute runtime
|
|
57
|
+
# Runtime the function is deployed on.
|
|
58
|
+
#
|
|
59
|
+
# @return [Symbol, Zavudev::Models::FunctionCreateResponse::Function::Runtime]
|
|
60
|
+
required :runtime, enum: -> { Zavudev::Models::FunctionCreateResponse::Function::Runtime }
|
|
61
|
+
|
|
62
|
+
# @!attribute slug
|
|
63
|
+
# URL-safe identifier, unique per project.
|
|
64
|
+
#
|
|
65
|
+
# @return [String]
|
|
66
|
+
required :slug, String
|
|
67
|
+
|
|
68
|
+
# @!attribute status
|
|
69
|
+
# Lifecycle status of a Zavu Function.
|
|
70
|
+
#
|
|
71
|
+
# @return [Symbol, Zavudev::Models::FunctionCreateResponse::Function::Status]
|
|
72
|
+
required :status, enum: -> { Zavudev::Models::FunctionCreateResponse::Function::Status }
|
|
73
|
+
|
|
74
|
+
# @!attribute timeout_sec
|
|
75
|
+
# Per-invocation timeout in seconds.
|
|
76
|
+
#
|
|
77
|
+
# @return [Integer]
|
|
78
|
+
required :timeout_sec, Integer, api_name: :timeoutSec
|
|
79
|
+
|
|
80
|
+
# @!attribute updated_at
|
|
81
|
+
#
|
|
82
|
+
# @return [Time]
|
|
83
|
+
required :updated_at, Time, api_name: :updatedAt
|
|
84
|
+
|
|
85
|
+
# @!attribute active_deployment_id
|
|
86
|
+
# ID of the deployment currently serving traffic.
|
|
87
|
+
#
|
|
88
|
+
# @return [String, nil]
|
|
89
|
+
optional :active_deployment_id, String, api_name: :activeDeploymentId, nil?: true
|
|
90
|
+
|
|
91
|
+
# @!attribute description
|
|
92
|
+
#
|
|
93
|
+
# @return [String, nil]
|
|
94
|
+
optional :description, String, nil?: true
|
|
95
|
+
|
|
96
|
+
# @!attribute public_url
|
|
97
|
+
# HTTPS endpoint when httpEnabled is true.
|
|
98
|
+
#
|
|
99
|
+
# @return [String, nil]
|
|
100
|
+
optional :public_url, String, api_name: :publicUrl, nil?: true
|
|
101
|
+
|
|
102
|
+
# @!method initialize(id:, created_at:, dependencies:, http_enabled:, memory_mb:, name:, runtime:, slug:, status:, timeout_sec:, updated_at:, active_deployment_id: nil, description: nil, public_url: nil)
|
|
103
|
+
# Some parameter documentations has been truncated, see
|
|
104
|
+
# {Zavudev::Models::FunctionCreateResponse::Function} for more details.
|
|
105
|
+
#
|
|
106
|
+
# A Zavu Function — user-supplied TypeScript that runs in Zavu Cloud and reacts to
|
|
107
|
+
# messaging events or HTTP requests.
|
|
108
|
+
#
|
|
109
|
+
# @param id [String]
|
|
110
|
+
#
|
|
111
|
+
# @param created_at [Time]
|
|
112
|
+
#
|
|
113
|
+
# @param dependencies [Hash{Symbol=>String}] npm dependencies installed in the function bundle. Keys are package names, value
|
|
114
|
+
#
|
|
115
|
+
# @param http_enabled [Boolean] Whether the function can be invoked over HTTPS via its public URL.
|
|
116
|
+
#
|
|
117
|
+
# @param memory_mb [Integer] Memory allocation in MB.
|
|
118
|
+
#
|
|
119
|
+
# @param name [String]
|
|
120
|
+
#
|
|
121
|
+
# @param runtime [Symbol, Zavudev::Models::FunctionCreateResponse::Function::Runtime] Runtime the function is deployed on.
|
|
122
|
+
#
|
|
123
|
+
# @param slug [String] URL-safe identifier, unique per project.
|
|
124
|
+
#
|
|
125
|
+
# @param status [Symbol, Zavudev::Models::FunctionCreateResponse::Function::Status] Lifecycle status of a Zavu Function.
|
|
126
|
+
#
|
|
127
|
+
# @param timeout_sec [Integer] Per-invocation timeout in seconds.
|
|
128
|
+
#
|
|
129
|
+
# @param updated_at [Time]
|
|
130
|
+
#
|
|
131
|
+
# @param active_deployment_id [String, nil] ID of the deployment currently serving traffic.
|
|
132
|
+
#
|
|
133
|
+
# @param description [String, nil]
|
|
134
|
+
#
|
|
135
|
+
# @param public_url [String, nil] HTTPS endpoint when httpEnabled is true.
|
|
136
|
+
|
|
137
|
+
# Runtime the function is deployed on.
|
|
138
|
+
#
|
|
139
|
+
# @see Zavudev::Models::FunctionCreateResponse::Function#runtime
|
|
140
|
+
module Runtime
|
|
141
|
+
extend Zavudev::Internal::Type::Enum
|
|
142
|
+
|
|
143
|
+
NODEJS24 = :nodejs24
|
|
144
|
+
|
|
145
|
+
# @!method self.values
|
|
146
|
+
# @return [Array<Symbol>]
|
|
147
|
+
end
|
|
148
|
+
|
|
149
|
+
# Lifecycle status of a Zavu Function.
|
|
150
|
+
#
|
|
151
|
+
# @see Zavudev::Models::FunctionCreateResponse::Function#status
|
|
152
|
+
module Status
|
|
153
|
+
extend Zavudev::Internal::Type::Enum
|
|
154
|
+
|
|
155
|
+
DRAFT = :draft
|
|
156
|
+
BUNDLING = :bundling
|
|
157
|
+
DEPLOYING = :deploying
|
|
158
|
+
ACTIVE = :active
|
|
159
|
+
FAILED = :failed
|
|
160
|
+
DISABLED = :disabled
|
|
161
|
+
|
|
162
|
+
# @!method self.values
|
|
163
|
+
# @return [Array<Symbol>]
|
|
164
|
+
end
|
|
165
|
+
end
|
|
166
|
+
end
|
|
167
|
+
end
|
|
168
|
+
end
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Zavudev
|
|
4
|
+
module Models
|
|
5
|
+
# @see Zavudev::Resources::Functions#delete
|
|
6
|
+
class FunctionDeleteParams < Zavudev::Internal::Type::BaseModel
|
|
7
|
+
extend Zavudev::Internal::Type::RequestParameters::Converter
|
|
8
|
+
include Zavudev::Internal::Type::RequestParameters
|
|
9
|
+
|
|
10
|
+
# @!attribute function_id
|
|
11
|
+
#
|
|
12
|
+
# @return [String]
|
|
13
|
+
required :function_id, String
|
|
14
|
+
|
|
15
|
+
# @!method initialize(function_id:, request_options: {})
|
|
16
|
+
# @param function_id [String]
|
|
17
|
+
# @param request_options [Zavudev::RequestOptions, Hash{Symbol=>Object}]
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
end
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Zavudev
|
|
4
|
+
module Models
|
|
5
|
+
# @see Zavudev::Resources::Functions#delete
|
|
6
|
+
class FunctionDeleteResponse < Zavudev::Internal::Type::BaseModel
|
|
7
|
+
# @!attribute deleted
|
|
8
|
+
#
|
|
9
|
+
# @return [Boolean]
|
|
10
|
+
required :deleted, Zavudev::Internal::Type::Boolean
|
|
11
|
+
|
|
12
|
+
# @!attribute name
|
|
13
|
+
#
|
|
14
|
+
# @return [String, nil]
|
|
15
|
+
optional :name, String
|
|
16
|
+
|
|
17
|
+
# @!attribute slug
|
|
18
|
+
#
|
|
19
|
+
# @return [String, nil]
|
|
20
|
+
optional :slug, String
|
|
21
|
+
|
|
22
|
+
# @!method initialize(deleted:, name: nil, slug: nil)
|
|
23
|
+
# @param deleted [Boolean]
|
|
24
|
+
# @param name [String]
|
|
25
|
+
# @param slug [String]
|
|
26
|
+
end
|
|
27
|
+
end
|
|
28
|
+
end
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Zavudev
|
|
4
|
+
module Models
|
|
5
|
+
# @see Zavudev::Resources::Functions#deploy
|
|
6
|
+
class FunctionDeployParams < Zavudev::Internal::Type::BaseModel
|
|
7
|
+
extend Zavudev::Internal::Type::RequestParameters::Converter
|
|
8
|
+
include Zavudev::Internal::Type::RequestParameters
|
|
9
|
+
|
|
10
|
+
# @!attribute function_id
|
|
11
|
+
#
|
|
12
|
+
# @return [String]
|
|
13
|
+
required :function_id, String
|
|
14
|
+
|
|
15
|
+
# @!attribute dependencies
|
|
16
|
+
# New dependency map (replaces existing dependencies).
|
|
17
|
+
#
|
|
18
|
+
# @return [Hash{Symbol=>String}, nil]
|
|
19
|
+
optional :dependencies, Zavudev::Internal::Type::HashOf[String]
|
|
20
|
+
|
|
21
|
+
# @!attribute source_code
|
|
22
|
+
# New source code to publish (replaces the draft).
|
|
23
|
+
#
|
|
24
|
+
# @return [String, nil]
|
|
25
|
+
optional :source_code, String, api_name: :sourceCode
|
|
26
|
+
|
|
27
|
+
# @!method initialize(function_id:, dependencies: nil, source_code: nil, request_options: {})
|
|
28
|
+
# @param function_id [String]
|
|
29
|
+
#
|
|
30
|
+
# @param dependencies [Hash{Symbol=>String}] New dependency map (replaces existing dependencies).
|
|
31
|
+
#
|
|
32
|
+
# @param source_code [String] New source code to publish (replaces the draft).
|
|
33
|
+
#
|
|
34
|
+
# @param request_options [Zavudev::RequestOptions, Hash{Symbol=>Object}]
|
|
35
|
+
end
|
|
36
|
+
end
|
|
37
|
+
end
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Zavudev
|
|
4
|
+
module Models
|
|
5
|
+
# @see Zavudev::Resources::Functions#deploy
|
|
6
|
+
class FunctionDeployResponse < Zavudev::Internal::Type::BaseModel
|
|
7
|
+
# @!attribute deployment
|
|
8
|
+
#
|
|
9
|
+
# @return [Zavudev::Models::FunctionDeployResponse::Deployment]
|
|
10
|
+
required :deployment, -> { Zavudev::Models::FunctionDeployResponse::Deployment }
|
|
11
|
+
|
|
12
|
+
# @!method initialize(deployment:)
|
|
13
|
+
# @param deployment [Zavudev::Models::FunctionDeployResponse::Deployment]
|
|
14
|
+
|
|
15
|
+
# @see Zavudev::Models::FunctionDeployResponse#deployment
|
|
16
|
+
class Deployment < Zavudev::Internal::Type::BaseModel
|
|
17
|
+
# @!attribute id
|
|
18
|
+
#
|
|
19
|
+
# @return [String]
|
|
20
|
+
required :id, String
|
|
21
|
+
|
|
22
|
+
# @!attribute created_at
|
|
23
|
+
#
|
|
24
|
+
# @return [Time]
|
|
25
|
+
required :created_at, Time, api_name: :createdAt
|
|
26
|
+
|
|
27
|
+
# @!attribute function_id
|
|
28
|
+
#
|
|
29
|
+
# @return [String]
|
|
30
|
+
required :function_id, String, api_name: :functionId
|
|
31
|
+
|
|
32
|
+
# @!attribute status
|
|
33
|
+
# Stage of a function deployment.
|
|
34
|
+
#
|
|
35
|
+
# @return [Symbol, Zavudev::Models::FunctionDeployResponse::Deployment::Status]
|
|
36
|
+
required :status, enum: -> { Zavudev::Models::FunctionDeployResponse::Deployment::Status }
|
|
37
|
+
|
|
38
|
+
# @!attribute version
|
|
39
|
+
# Monotonically increasing deployment version, starting at 1.
|
|
40
|
+
#
|
|
41
|
+
# @return [Integer]
|
|
42
|
+
required :version, Integer
|
|
43
|
+
|
|
44
|
+
# @!attribute bundle_bytes
|
|
45
|
+
#
|
|
46
|
+
# @return [Integer, nil]
|
|
47
|
+
optional :bundle_bytes, Integer, api_name: :bundleBytes, nil?: true
|
|
48
|
+
|
|
49
|
+
# @!attribute deployed_at
|
|
50
|
+
#
|
|
51
|
+
# @return [Time, nil]
|
|
52
|
+
optional :deployed_at, Time, api_name: :deployedAt, nil?: true
|
|
53
|
+
|
|
54
|
+
# @!attribute error_message
|
|
55
|
+
# Failure reason when status is 'failed'.
|
|
56
|
+
#
|
|
57
|
+
# @return [String, nil]
|
|
58
|
+
optional :error_message, String, api_name: :errorMessage, nil?: true
|
|
59
|
+
|
|
60
|
+
# @!attribute source_code_bytes
|
|
61
|
+
#
|
|
62
|
+
# @return [Integer, nil]
|
|
63
|
+
optional :source_code_bytes, Integer, api_name: :sourceCodeBytes, nil?: true
|
|
64
|
+
|
|
65
|
+
# @!method initialize(id:, created_at:, function_id:, status:, version:, bundle_bytes: nil, deployed_at: nil, error_message: nil, source_code_bytes: nil)
|
|
66
|
+
# @param id [String]
|
|
67
|
+
#
|
|
68
|
+
# @param created_at [Time]
|
|
69
|
+
#
|
|
70
|
+
# @param function_id [String]
|
|
71
|
+
#
|
|
72
|
+
# @param status [Symbol, Zavudev::Models::FunctionDeployResponse::Deployment::Status] Stage of a function deployment.
|
|
73
|
+
#
|
|
74
|
+
# @param version [Integer] Monotonically increasing deployment version, starting at 1.
|
|
75
|
+
#
|
|
76
|
+
# @param bundle_bytes [Integer, nil]
|
|
77
|
+
#
|
|
78
|
+
# @param deployed_at [Time, nil]
|
|
79
|
+
#
|
|
80
|
+
# @param error_message [String, nil] Failure reason when status is 'failed'.
|
|
81
|
+
#
|
|
82
|
+
# @param source_code_bytes [Integer, nil]
|
|
83
|
+
|
|
84
|
+
# Stage of a function deployment.
|
|
85
|
+
#
|
|
86
|
+
# @see Zavudev::Models::FunctionDeployResponse::Deployment#status
|
|
87
|
+
module Status
|
|
88
|
+
extend Zavudev::Internal::Type::Enum
|
|
89
|
+
|
|
90
|
+
PENDING = :pending
|
|
91
|
+
BUNDLING = :bundling
|
|
92
|
+
UPLOADING = :uploading
|
|
93
|
+
PUBLISHING = :publishing
|
|
94
|
+
ACTIVE = :active
|
|
95
|
+
FAILED = :failed
|
|
96
|
+
SUPERSEDED = :superseded
|
|
97
|
+
|
|
98
|
+
# @!method self.values
|
|
99
|
+
# @return [Array<Symbol>]
|
|
100
|
+
end
|
|
101
|
+
end
|
|
102
|
+
end
|
|
103
|
+
end
|
|
104
|
+
end
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Zavudev
|
|
4
|
+
module Models
|
|
5
|
+
# @see Zavudev::Resources::Functions#get_deployment
|
|
6
|
+
class FunctionGetDeploymentParams < Zavudev::Internal::Type::BaseModel
|
|
7
|
+
extend Zavudev::Internal::Type::RequestParameters::Converter
|
|
8
|
+
include Zavudev::Internal::Type::RequestParameters
|
|
9
|
+
|
|
10
|
+
# @!attribute deployment_id
|
|
11
|
+
#
|
|
12
|
+
# @return [String]
|
|
13
|
+
required :deployment_id, String
|
|
14
|
+
|
|
15
|
+
# @!method initialize(deployment_id:, request_options: {})
|
|
16
|
+
# @param deployment_id [String]
|
|
17
|
+
# @param request_options [Zavudev::RequestOptions, Hash{Symbol=>Object}]
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
end
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Zavudev
|
|
4
|
+
module Models
|
|
5
|
+
# @see Zavudev::Resources::Functions#get_deployment
|
|
6
|
+
class FunctionGetDeploymentResponse < Zavudev::Internal::Type::BaseModel
|
|
7
|
+
# @!attribute deployment
|
|
8
|
+
#
|
|
9
|
+
# @return [Zavudev::Models::FunctionGetDeploymentResponse::Deployment]
|
|
10
|
+
required :deployment, -> { Zavudev::Models::FunctionGetDeploymentResponse::Deployment }
|
|
11
|
+
|
|
12
|
+
# @!method initialize(deployment:)
|
|
13
|
+
# @param deployment [Zavudev::Models::FunctionGetDeploymentResponse::Deployment]
|
|
14
|
+
|
|
15
|
+
# @see Zavudev::Models::FunctionGetDeploymentResponse#deployment
|
|
16
|
+
class Deployment < Zavudev::Internal::Type::BaseModel
|
|
17
|
+
# @!attribute id
|
|
18
|
+
#
|
|
19
|
+
# @return [String]
|
|
20
|
+
required :id, String
|
|
21
|
+
|
|
22
|
+
# @!attribute created_at
|
|
23
|
+
#
|
|
24
|
+
# @return [Time]
|
|
25
|
+
required :created_at, Time, api_name: :createdAt
|
|
26
|
+
|
|
27
|
+
# @!attribute function_id
|
|
28
|
+
#
|
|
29
|
+
# @return [String]
|
|
30
|
+
required :function_id, String, api_name: :functionId
|
|
31
|
+
|
|
32
|
+
# @!attribute status
|
|
33
|
+
# Stage of a function deployment.
|
|
34
|
+
#
|
|
35
|
+
# @return [Symbol, Zavudev::Models::FunctionGetDeploymentResponse::Deployment::Status]
|
|
36
|
+
required :status, enum: -> { Zavudev::Models::FunctionGetDeploymentResponse::Deployment::Status }
|
|
37
|
+
|
|
38
|
+
# @!attribute version
|
|
39
|
+
# Monotonically increasing deployment version, starting at 1.
|
|
40
|
+
#
|
|
41
|
+
# @return [Integer]
|
|
42
|
+
required :version, Integer
|
|
43
|
+
|
|
44
|
+
# @!attribute bundle_bytes
|
|
45
|
+
#
|
|
46
|
+
# @return [Integer, nil]
|
|
47
|
+
optional :bundle_bytes, Integer, api_name: :bundleBytes, nil?: true
|
|
48
|
+
|
|
49
|
+
# @!attribute deployed_at
|
|
50
|
+
#
|
|
51
|
+
# @return [Time, nil]
|
|
52
|
+
optional :deployed_at, Time, api_name: :deployedAt, nil?: true
|
|
53
|
+
|
|
54
|
+
# @!attribute error_message
|
|
55
|
+
# Failure reason when status is 'failed'.
|
|
56
|
+
#
|
|
57
|
+
# @return [String, nil]
|
|
58
|
+
optional :error_message, String, api_name: :errorMessage, nil?: true
|
|
59
|
+
|
|
60
|
+
# @!attribute source_code_bytes
|
|
61
|
+
#
|
|
62
|
+
# @return [Integer, nil]
|
|
63
|
+
optional :source_code_bytes, Integer, api_name: :sourceCodeBytes, nil?: true
|
|
64
|
+
|
|
65
|
+
# @!method initialize(id:, created_at:, function_id:, status:, version:, bundle_bytes: nil, deployed_at: nil, error_message: nil, source_code_bytes: nil)
|
|
66
|
+
# @param id [String]
|
|
67
|
+
#
|
|
68
|
+
# @param created_at [Time]
|
|
69
|
+
#
|
|
70
|
+
# @param function_id [String]
|
|
71
|
+
#
|
|
72
|
+
# @param status [Symbol, Zavudev::Models::FunctionGetDeploymentResponse::Deployment::Status] Stage of a function deployment.
|
|
73
|
+
#
|
|
74
|
+
# @param version [Integer] Monotonically increasing deployment version, starting at 1.
|
|
75
|
+
#
|
|
76
|
+
# @param bundle_bytes [Integer, nil]
|
|
77
|
+
#
|
|
78
|
+
# @param deployed_at [Time, nil]
|
|
79
|
+
#
|
|
80
|
+
# @param error_message [String, nil] Failure reason when status is 'failed'.
|
|
81
|
+
#
|
|
82
|
+
# @param source_code_bytes [Integer, nil]
|
|
83
|
+
|
|
84
|
+
# Stage of a function deployment.
|
|
85
|
+
#
|
|
86
|
+
# @see Zavudev::Models::FunctionGetDeploymentResponse::Deployment#status
|
|
87
|
+
module Status
|
|
88
|
+
extend Zavudev::Internal::Type::Enum
|
|
89
|
+
|
|
90
|
+
PENDING = :pending
|
|
91
|
+
BUNDLING = :bundling
|
|
92
|
+
UPLOADING = :uploading
|
|
93
|
+
PUBLISHING = :publishing
|
|
94
|
+
ACTIVE = :active
|
|
95
|
+
FAILED = :failed
|
|
96
|
+
SUPERSEDED = :superseded
|
|
97
|
+
|
|
98
|
+
# @!method self.values
|
|
99
|
+
# @return [Array<Symbol>]
|
|
100
|
+
end
|
|
101
|
+
end
|
|
102
|
+
end
|
|
103
|
+
end
|
|
104
|
+
end
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Zavudev
|
|
4
|
+
module Models
|
|
5
|
+
# @see Zavudev::Resources::Functions#retrieve
|
|
6
|
+
class FunctionRetrieveParams < Zavudev::Internal::Type::BaseModel
|
|
7
|
+
extend Zavudev::Internal::Type::RequestParameters::Converter
|
|
8
|
+
include Zavudev::Internal::Type::RequestParameters
|
|
9
|
+
|
|
10
|
+
# @!attribute function_id
|
|
11
|
+
#
|
|
12
|
+
# @return [String]
|
|
13
|
+
required :function_id, String
|
|
14
|
+
|
|
15
|
+
# @!method initialize(function_id:, request_options: {})
|
|
16
|
+
# @param function_id [String]
|
|
17
|
+
# @param request_options [Zavudev::RequestOptions, Hash{Symbol=>Object}]
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
end
|