dyspatch_client 2.0.0 → 3.0.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 +5 -5
- data/README.md +42 -16
- data/docs/APIError.md +1 -1
- data/docs/Body.md +8 -0
- data/docs/Body1.md +8 -0
- data/docs/CreatedAt.md +7 -0
- data/docs/DraftDescription.md +7 -0
- data/docs/DraftId.md +7 -0
- data/docs/DraftMetaRead.md +14 -0
- data/docs/DraftName.md +7 -0
- data/docs/DraftRead.md +15 -0
- data/docs/DraftUrl.md +7 -0
- data/docs/DraftsApi.md +467 -0
- data/docs/DraftsRead.md +9 -0
- data/docs/LanguageId.md +7 -0
- data/docs/LocalizationId.md +7 -0
- data/docs/LocalizationKeyRead.md +9 -0
- data/docs/LocalizationMetaRead.md +1 -0
- data/docs/LocalizationName.md +7 -0
- data/docs/LocalizationUrl.md +7 -0
- data/docs/LocalizationsApi.md +8 -11
- data/docs/TemplateDescription.md +7 -0
- data/docs/TemplateId.md +7 -0
- data/docs/TemplateMetaRead.md +1 -1
- data/docs/TemplateName.md +7 -0
- data/docs/TemplateRead.md +1 -1
- data/docs/TemplateUrl.md +7 -0
- data/docs/TemplatesApi.md +9 -14
- data/docs/TemplatesRead.md +1 -1
- data/docs/UpdatedAt.md +7 -0
- data/dyspatch_client.gemspec +8 -8
- data/lib/dyspatch_client.rb +24 -3
- data/lib/dyspatch_client/api/drafts_api.rb +479 -0
- data/lib/dyspatch_client/api/localizations_api.rb +23 -22
- data/lib/dyspatch_client/api/templates_api.rb +25 -28
- data/lib/dyspatch_client/api_client.rb +11 -11
- data/lib/dyspatch_client/api_error.rb +3 -3
- data/lib/dyspatch_client/configuration.rb +4 -4
- data/lib/dyspatch_client/models/api_error.rb +11 -15
- data/lib/dyspatch_client/models/body.rb +183 -0
- data/lib/dyspatch_client/models/body_1.rb +183 -0
- data/lib/dyspatch_client/models/compiled_read.rb +14 -22
- data/lib/dyspatch_client/models/created_at.rb +175 -0
- data/lib/dyspatch_client/models/cursor.rb +8 -12
- data/lib/dyspatch_client/models/draft_description.rb +175 -0
- data/lib/dyspatch_client/models/draft_id.rb +175 -0
- data/lib/dyspatch_client/models/draft_meta_read.rb +244 -0
- data/lib/dyspatch_client/models/draft_name.rb +175 -0
- data/lib/dyspatch_client/models/draft_read.rb +255 -0
- data/lib/dyspatch_client/models/draft_url.rb +175 -0
- data/lib/dyspatch_client/models/drafts_read.rb +196 -0
- data/lib/dyspatch_client/models/language_id.rb +175 -0
- data/lib/dyspatch_client/models/localization_id.rb +175 -0
- data/lib/dyspatch_client/models/localization_key_read.rb +192 -0
- data/lib/dyspatch_client/models/localization_meta_read.rb +20 -15
- data/lib/dyspatch_client/models/localization_name.rb +175 -0
- data/lib/dyspatch_client/models/localization_read.rb +8 -13
- data/lib/dyspatch_client/models/localization_url.rb +175 -0
- data/lib/dyspatch_client/models/template_description.rb +175 -0
- data/lib/dyspatch_client/models/template_id.rb +175 -0
- data/lib/dyspatch_client/models/template_meta_read.rb +8 -13
- data/lib/dyspatch_client/models/template_name.rb +175 -0
- data/lib/dyspatch_client/models/template_read.rb +8 -13
- data/lib/dyspatch_client/models/template_url.rb +175 -0
- data/lib/dyspatch_client/models/templates_read.rb +8 -13
- data/lib/dyspatch_client/models/updated_at.rb +175 -0
- data/lib/dyspatch_client/version.rb +4 -4
- data/spec/api/drafts_api_spec.rb +138 -0
- data/spec/api/localizations_api_spec.rb +6 -7
- data/spec/api/templates_api_spec.rb +6 -8
- data/spec/api_client_spec.rb +37 -37
- data/spec/configuration_spec.rb +11 -11
- data/spec/models/api_error_spec.rb +10 -11
- data/spec/models/body_1_spec.rb +41 -0
- data/spec/models/body_spec.rb +41 -0
- data/spec/models/compiled_read_spec.rb +8 -9
- data/spec/models/created_at_spec.rb +35 -0
- data/spec/models/cursor_spec.rb +5 -6
- data/spec/models/draft_description_spec.rb +35 -0
- data/spec/models/draft_id_spec.rb +35 -0
- data/spec/models/draft_meta_read_spec.rb +77 -0
- data/spec/models/draft_name_spec.rb +35 -0
- data/spec/models/draft_read_spec.rb +83 -0
- data/spec/models/draft_url_spec.rb +35 -0
- data/spec/models/drafts_read_spec.rb +47 -0
- data/spec/models/language_id_spec.rb +35 -0
- data/spec/models/localization_id_spec.rb +35 -0
- data/spec/models/localization_key_read_spec.rb +47 -0
- data/spec/models/localization_meta_read_spec.rb +13 -8
- data/spec/models/localization_name_spec.rb +35 -0
- data/spec/models/localization_read_spec.rb +11 -12
- data/spec/models/localization_url_spec.rb +35 -0
- data/spec/models/template_description_spec.rb +35 -0
- data/spec/models/template_id_spec.rb +35 -0
- data/spec/models/template_meta_read_spec.rb +10 -11
- data/spec/models/template_name_spec.rb +35 -0
- data/spec/models/template_read_spec.rb +11 -12
- data/spec/models/template_url_spec.rb +35 -0
- data/spec/models/templates_read_spec.rb +5 -6
- data/spec/models/updated_at_spec.rb +35 -0
- data/spec/spec_helper.rb +3 -3
- metadata +106 -22
@@ -1,26 +1,24 @@
|
|
1
1
|
=begin
|
2
2
|
#Dyspatch API
|
3
3
|
|
4
|
-
## Introduction The Dyspatch API is based on the REST paradigm
|
4
|
+
## Introduction The Dyspatch API is based on the REST paradigm and features resource based URLs with standard HTTP response codes to indicate errors. We use standard HTTP authentication and request verbs and all responses are JSON formatted. See our [Implementation Guide](https://docs.dyspatch.io/development/implementing_dyspatch/) for more details on how to implement Dyspatch. ## API Client Libraries Dyspatch provides API Clients for the following languages and web frameworks: - [Java](https://github.com/getdyspatch/dyspatch-java) - [Javascript](https://github.com/getdyspatch/dyspatch-javascript) - [Python](https://github.com/getdyspatch/dyspatch-python) - [C#](https://github.com/getdyspatch/dyspatch-dotnet) - [Go](https://github.com/getdyspatch/dyspatch-golang) - [Ruby](https://github.com/getdyspatch/dyspatch-ruby)
|
5
5
|
|
6
|
-
OpenAPI spec version: 2019.
|
6
|
+
OpenAPI spec version: 2019.10
|
7
7
|
Contact: support@dyspatch.io
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.9
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
require 'date'
|
14
14
|
|
15
15
|
module DyspatchClient
|
16
|
-
|
17
16
|
class TemplatesRead
|
18
17
|
attr_accessor :cursor
|
19
18
|
|
20
19
|
# A list of template metadata objects
|
21
20
|
attr_accessor :data
|
22
21
|
|
23
|
-
|
24
22
|
# Attribute mapping from ruby-style variable name to JSON key.
|
25
23
|
def self.attribute_map
|
26
24
|
{
|
@@ -43,7 +41,7 @@ module DyspatchClient
|
|
43
41
|
return unless attributes.is_a?(Hash)
|
44
42
|
|
45
43
|
# convert string to symbol for hash key
|
46
|
-
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
44
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
47
45
|
|
48
46
|
if attributes.has_key?(:'cursor')
|
49
47
|
self.cursor = attributes[:'cursor']
|
@@ -54,20 +52,19 @@ module DyspatchClient
|
|
54
52
|
self.data = value
|
55
53
|
end
|
56
54
|
end
|
57
|
-
|
58
55
|
end
|
59
56
|
|
60
57
|
# Show invalid properties with the reasons. Usually used together with valid?
|
61
58
|
# @return Array for valid properties with the reasons
|
62
59
|
def list_invalid_properties
|
63
60
|
invalid_properties = Array.new
|
64
|
-
|
61
|
+
invalid_properties
|
65
62
|
end
|
66
63
|
|
67
64
|
# Check to see if the all the properties in the model are valid
|
68
65
|
# @return true if the model is valid
|
69
66
|
def valid?
|
70
|
-
|
67
|
+
true
|
71
68
|
end
|
72
69
|
|
73
70
|
# Checks equality by comparing each attribute.
|
@@ -101,7 +98,7 @@ module DyspatchClient
|
|
101
98
|
# check to ensure the input is an array given that the the attribute
|
102
99
|
# is documented as an array but the input is not
|
103
100
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
104
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) }
|
101
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
105
102
|
end
|
106
103
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
107
104
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
@@ -183,7 +180,7 @@ module DyspatchClient
|
|
183
180
|
# @return [Hash] Returns the value in the form of hash
|
184
181
|
def _to_hash(value)
|
185
182
|
if value.is_a?(Array)
|
186
|
-
value.compact.map{ |v| _to_hash(v) }
|
183
|
+
value.compact.map { |v| _to_hash(v) }
|
187
184
|
elsif value.is_a?(Hash)
|
188
185
|
{}.tap do |hash|
|
189
186
|
value.each { |k, v| hash[k] = _to_hash(v) }
|
@@ -194,7 +191,5 @@ module DyspatchClient
|
|
194
191
|
value
|
195
192
|
end
|
196
193
|
end
|
197
|
-
|
198
194
|
end
|
199
|
-
|
200
195
|
end
|
@@ -0,0 +1,175 @@
|
|
1
|
+
=begin
|
2
|
+
#Dyspatch API
|
3
|
+
|
4
|
+
## Introduction The Dyspatch API is based on the REST paradigm and features resource based URLs with standard HTTP response codes to indicate errors. We use standard HTTP authentication and request verbs and all responses are JSON formatted. See our [Implementation Guide](https://docs.dyspatch.io/development/implementing_dyspatch/) for more details on how to implement Dyspatch. ## API Client Libraries Dyspatch provides API Clients for the following languages and web frameworks: - [Java](https://github.com/getdyspatch/dyspatch-java) - [Javascript](https://github.com/getdyspatch/dyspatch-javascript) - [Python](https://github.com/getdyspatch/dyspatch-python) - [C#](https://github.com/getdyspatch/dyspatch-dotnet) - [Go](https://github.com/getdyspatch/dyspatch-golang) - [Ruby](https://github.com/getdyspatch/dyspatch-ruby)
|
5
|
+
|
6
|
+
OpenAPI spec version: 2019.10
|
7
|
+
Contact: support@dyspatch.io
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 2.4.9
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module DyspatchClient
|
16
|
+
# The time of last update
|
17
|
+
class UpdatedAt
|
18
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
19
|
+
def self.attribute_map
|
20
|
+
{
|
21
|
+
}
|
22
|
+
end
|
23
|
+
|
24
|
+
# Attribute type mapping.
|
25
|
+
def self.swagger_types
|
26
|
+
{
|
27
|
+
}
|
28
|
+
end
|
29
|
+
|
30
|
+
# Initializes the object
|
31
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
32
|
+
def initialize(attributes = {})
|
33
|
+
return unless attributes.is_a?(Hash)
|
34
|
+
|
35
|
+
# convert string to symbol for hash key
|
36
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
37
|
+
end
|
38
|
+
|
39
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
40
|
+
# @return Array for valid properties with the reasons
|
41
|
+
def list_invalid_properties
|
42
|
+
invalid_properties = Array.new
|
43
|
+
invalid_properties
|
44
|
+
end
|
45
|
+
|
46
|
+
# Check to see if the all the properties in the model are valid
|
47
|
+
# @return true if the model is valid
|
48
|
+
def valid?
|
49
|
+
true
|
50
|
+
end
|
51
|
+
|
52
|
+
# Checks equality by comparing each attribute.
|
53
|
+
# @param [Object] Object to be compared
|
54
|
+
def ==(o)
|
55
|
+
return true if self.equal?(o)
|
56
|
+
self.class == o.class
|
57
|
+
end
|
58
|
+
|
59
|
+
# @see the `==` method
|
60
|
+
# @param [Object] Object to be compared
|
61
|
+
def eql?(o)
|
62
|
+
self == o
|
63
|
+
end
|
64
|
+
|
65
|
+
# Calculates hash code according to all attributes.
|
66
|
+
# @return [Fixnum] Hash code
|
67
|
+
def hash
|
68
|
+
[].hash
|
69
|
+
end
|
70
|
+
|
71
|
+
# Builds the object from hash
|
72
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
73
|
+
# @return [Object] Returns the model itself
|
74
|
+
def build_from_hash(attributes)
|
75
|
+
return nil unless attributes.is_a?(Hash)
|
76
|
+
self.class.swagger_types.each_pair do |key, type|
|
77
|
+
if type =~ /\AArray<(.*)>/i
|
78
|
+
# check to ensure the input is an array given that the the attribute
|
79
|
+
# is documented as an array but the input is not
|
80
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
81
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
82
|
+
end
|
83
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
84
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
85
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
86
|
+
end
|
87
|
+
|
88
|
+
self
|
89
|
+
end
|
90
|
+
|
91
|
+
# Deserializes the data based on type
|
92
|
+
# @param string type Data type
|
93
|
+
# @param string value Value to be deserialized
|
94
|
+
# @return [Object] Deserialized data
|
95
|
+
def _deserialize(type, value)
|
96
|
+
case type.to_sym
|
97
|
+
when :DateTime
|
98
|
+
DateTime.parse(value)
|
99
|
+
when :Date
|
100
|
+
Date.parse(value)
|
101
|
+
when :String
|
102
|
+
value.to_s
|
103
|
+
when :Integer
|
104
|
+
value.to_i
|
105
|
+
when :Float
|
106
|
+
value.to_f
|
107
|
+
when :BOOLEAN
|
108
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
109
|
+
true
|
110
|
+
else
|
111
|
+
false
|
112
|
+
end
|
113
|
+
when :Object
|
114
|
+
# generic object (usually a Hash), return directly
|
115
|
+
value
|
116
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
117
|
+
inner_type = Regexp.last_match[:inner_type]
|
118
|
+
value.map { |v| _deserialize(inner_type, v) }
|
119
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
120
|
+
k_type = Regexp.last_match[:k_type]
|
121
|
+
v_type = Regexp.last_match[:v_type]
|
122
|
+
{}.tap do |hash|
|
123
|
+
value.each do |k, v|
|
124
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
125
|
+
end
|
126
|
+
end
|
127
|
+
else # model
|
128
|
+
temp_model = DyspatchClient.const_get(type).new
|
129
|
+
temp_model.build_from_hash(value)
|
130
|
+
end
|
131
|
+
end
|
132
|
+
|
133
|
+
# Returns the string representation of the object
|
134
|
+
# @return [String] String presentation of the object
|
135
|
+
def to_s
|
136
|
+
to_hash.to_s
|
137
|
+
end
|
138
|
+
|
139
|
+
# to_body is an alias to to_hash (backward compatibility)
|
140
|
+
# @return [Hash] Returns the object in the form of hash
|
141
|
+
def to_body
|
142
|
+
to_hash
|
143
|
+
end
|
144
|
+
|
145
|
+
# Returns the object in the form of hash
|
146
|
+
# @return [Hash] Returns the object in the form of hash
|
147
|
+
def to_hash
|
148
|
+
hash = {}
|
149
|
+
self.class.attribute_map.each_pair do |attr, param|
|
150
|
+
value = self.send(attr)
|
151
|
+
next if value.nil?
|
152
|
+
hash[param] = _to_hash(value)
|
153
|
+
end
|
154
|
+
hash
|
155
|
+
end
|
156
|
+
|
157
|
+
# Outputs non-array value in the form of hash
|
158
|
+
# For object, use to_hash. Otherwise, just return the value
|
159
|
+
# @param [Object] value Any valid value
|
160
|
+
# @return [Hash] Returns the value in the form of hash
|
161
|
+
def _to_hash(value)
|
162
|
+
if value.is_a?(Array)
|
163
|
+
value.compact.map { |v| _to_hash(v) }
|
164
|
+
elsif value.is_a?(Hash)
|
165
|
+
{}.tap do |hash|
|
166
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
167
|
+
end
|
168
|
+
elsif value.respond_to? :to_hash
|
169
|
+
value.to_hash
|
170
|
+
else
|
171
|
+
value
|
172
|
+
end
|
173
|
+
end
|
174
|
+
end
|
175
|
+
end
|
@@ -1,15 +1,15 @@
|
|
1
1
|
=begin
|
2
2
|
#Dyspatch API
|
3
3
|
|
4
|
-
## Introduction The Dyspatch API is based on the REST paradigm
|
4
|
+
## Introduction The Dyspatch API is based on the REST paradigm and features resource based URLs with standard HTTP response codes to indicate errors. We use standard HTTP authentication and request verbs and all responses are JSON formatted. See our [Implementation Guide](https://docs.dyspatch.io/development/implementing_dyspatch/) for more details on how to implement Dyspatch. ## API Client Libraries Dyspatch provides API Clients for the following languages and web frameworks: - [Java](https://github.com/getdyspatch/dyspatch-java) - [Javascript](https://github.com/getdyspatch/dyspatch-javascript) - [Python](https://github.com/getdyspatch/dyspatch-python) - [C#](https://github.com/getdyspatch/dyspatch-dotnet) - [Go](https://github.com/getdyspatch/dyspatch-golang) - [Ruby](https://github.com/getdyspatch/dyspatch-ruby)
|
5
5
|
|
6
|
-
OpenAPI spec version: 2019.
|
6
|
+
OpenAPI spec version: 2019.10
|
7
7
|
Contact: support@dyspatch.io
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.9
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
module DyspatchClient
|
14
|
-
VERSION =
|
14
|
+
VERSION = '3.0.0'
|
15
15
|
end
|
@@ -0,0 +1,138 @@
|
|
1
|
+
=begin
|
2
|
+
#Dyspatch API
|
3
|
+
|
4
|
+
## Introduction The Dyspatch API is based on the REST paradigm and features resource based URLs with standard HTTP response codes to indicate errors. We use standard HTTP authentication and request verbs and all responses are JSON formatted. See our [Implementation Guide](https://docs.dyspatch.io/development/implementing_dyspatch/) for more details on how to implement Dyspatch. ## API Client Libraries Dyspatch provides API Clients for the following languages and web frameworks: - [Java](https://github.com/getdyspatch/dyspatch-java) - [Javascript](https://github.com/getdyspatch/dyspatch-javascript) - [Python](https://github.com/getdyspatch/dyspatch-python) - [C#](https://github.com/getdyspatch/dyspatch-dotnet) - [Go](https://github.com/getdyspatch/dyspatch-golang) - [Ruby](https://github.com/getdyspatch/dyspatch-ruby)
|
5
|
+
|
6
|
+
OpenAPI spec version: 2019.10
|
7
|
+
Contact: support@dyspatch.io
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 2.4.9
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for DyspatchClient::DraftsApi
|
17
|
+
# Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'DraftsApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@instance = DyspatchClient::DraftsApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of DraftsApi' do
|
30
|
+
it 'should create an instance of DraftsApi' do
|
31
|
+
expect(@instance).to be_instance_of(DyspatchClient::DraftsApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for drafts_draft_id_get
|
36
|
+
# Get Draft by ID
|
37
|
+
# Gets a draft object with the matching ID. The "compiled" field will contain the unlocalized default template object.
|
38
|
+
# @param draft_id A draft ID
|
39
|
+
# @param target_language The type of templating language to compile as. Should only be used for visual templates.
|
40
|
+
# @param [Hash] opts the optional parameters
|
41
|
+
# @return [DraftRead]
|
42
|
+
describe 'drafts_draft_id_get test' do
|
43
|
+
it 'should work' do
|
44
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
# unit tests for drafts_draft_id_localization_keys_get
|
49
|
+
# Get Localization Keys
|
50
|
+
# Returns the list of values that need to be translated for the draft. Set the `Accept` header to `application/vnd.dyspatch.2019.10+json` to get a JSON object, or `text/vnd.dyspatch.2019.10+x-gettext-translation` to get the POT file.
|
51
|
+
# @param draft_id A draft ID
|
52
|
+
# @param [Hash] opts the optional parameters
|
53
|
+
# @option opts [String] :accept A version of the API that should be used for the request. For example, to use version "2019.10", set the value to "application/vnd.dyspatch.2019.10+json".
|
54
|
+
# @return [Array<LocalizationKeyRead>]
|
55
|
+
describe 'drafts_draft_id_localization_keys_get test' do
|
56
|
+
it 'should work' do
|
57
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
58
|
+
end
|
59
|
+
end
|
60
|
+
|
61
|
+
# unit tests for drafts_draft_id_localizations_get
|
62
|
+
# Get Localizations on a Draft
|
63
|
+
# Returns localization metadata object for a template draft.
|
64
|
+
# @param draft_id A draft ID
|
65
|
+
# @param [Hash] opts the optional parameters
|
66
|
+
# @return [Array<LocalizationMetaRead>]
|
67
|
+
describe 'drafts_draft_id_localizations_get test' do
|
68
|
+
it 'should work' do
|
69
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
70
|
+
end
|
71
|
+
end
|
72
|
+
|
73
|
+
# unit tests for drafts_draft_id_localizations_language_id_delete
|
74
|
+
# Remove a Localization
|
75
|
+
# Deletes the localization with the given `languageId` if it exists.
|
76
|
+
# @param draft_id A draft ID
|
77
|
+
# @param language_id A language ID (eg: en-US)
|
78
|
+
# @param [Hash] opts the optional parameters
|
79
|
+
# @return [nil]
|
80
|
+
describe 'drafts_draft_id_localizations_language_id_delete test' do
|
81
|
+
it 'should work' do
|
82
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
83
|
+
end
|
84
|
+
end
|
85
|
+
|
86
|
+
# unit tests for drafts_draft_id_localizations_language_id_put
|
87
|
+
# Create or Update a Localization
|
88
|
+
# Inserts a localization or sets the name on an existing localization that already uses the `languageId`.
|
89
|
+
# @param draft_id A draft ID
|
90
|
+
# @param language_id A language ID (eg: en-US)
|
91
|
+
# @param body
|
92
|
+
# @param [Hash] opts the optional parameters
|
93
|
+
# @return [nil]
|
94
|
+
describe 'drafts_draft_id_localizations_language_id_put test' do
|
95
|
+
it 'should work' do
|
96
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
97
|
+
end
|
98
|
+
end
|
99
|
+
|
100
|
+
# unit tests for drafts_draft_id_localizations_language_id_translations_put
|
101
|
+
# Set Translations for Language
|
102
|
+
# Completely replaces any existing translations for the given language with those provided in request body. Variables embedded in keys or values are expected to be in the format `%(my_variable)s` and will automatically convert to the correct Dyspatch format depending on the type of template. Accepts key/value pairs in JSON format or in gettext PO file format. For JSON set `Content-Type` header to `application/json`. For gettext PO format set `Content-Type` header to `text/x-gettext-translation`.
|
103
|
+
# @param draft_id A draft ID
|
104
|
+
# @param language_id A language ID (eg: en-US)
|
105
|
+
# @param body
|
106
|
+
# @param [Hash] opts the optional parameters
|
107
|
+
# @return [nil]
|
108
|
+
describe 'drafts_draft_id_localizations_language_id_translations_put test' do
|
109
|
+
it 'should work' do
|
110
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
111
|
+
end
|
112
|
+
end
|
113
|
+
|
114
|
+
# unit tests for drafts_draft_id_publish_request_post
|
115
|
+
# Submit the Draft for Approval
|
116
|
+
# Moves the draft into [submitted and locked state](https://docs.dyspatch.io/templates/submitting_a_template/#awaiting-approval). This will allow your email stakeholders to review the template draft and provide feedback.
|
117
|
+
# @param draft_id A draft ID
|
118
|
+
# @param [Hash] opts the optional parameters
|
119
|
+
# @return [nil]
|
120
|
+
describe 'drafts_draft_id_publish_request_post test' do
|
121
|
+
it 'should work' do
|
122
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
123
|
+
end
|
124
|
+
end
|
125
|
+
|
126
|
+
# unit tests for drafts_get
|
127
|
+
# List Drafts
|
128
|
+
# Gets a list of all drafts for your oranization. Up to 25 results returned before results are paginated.
|
129
|
+
# @param [Hash] opts the optional parameters
|
130
|
+
# @option opts [String] :status Filter the list of drafts by a particular status
|
131
|
+
# @return [DraftsRead]
|
132
|
+
describe 'drafts_get test' do
|
133
|
+
it 'should work' do
|
134
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
135
|
+
end
|
136
|
+
end
|
137
|
+
|
138
|
+
end
|
@@ -1,12 +1,12 @@
|
|
1
1
|
=begin
|
2
2
|
#Dyspatch API
|
3
3
|
|
4
|
-
## Introduction The Dyspatch API is based on the REST paradigm
|
4
|
+
## Introduction The Dyspatch API is based on the REST paradigm and features resource based URLs with standard HTTP response codes to indicate errors. We use standard HTTP authentication and request verbs and all responses are JSON formatted. See our [Implementation Guide](https://docs.dyspatch.io/development/implementing_dyspatch/) for more details on how to implement Dyspatch. ## API Client Libraries Dyspatch provides API Clients for the following languages and web frameworks: - [Java](https://github.com/getdyspatch/dyspatch-java) - [Javascript](https://github.com/getdyspatch/dyspatch-javascript) - [Python](https://github.com/getdyspatch/dyspatch-python) - [C#](https://github.com/getdyspatch/dyspatch-dotnet) - [Go](https://github.com/getdyspatch/dyspatch-golang) - [Ruby](https://github.com/getdyspatch/dyspatch-ruby)
|
5
5
|
|
6
|
-
OpenAPI spec version: 2019.
|
6
|
+
OpenAPI spec version: 2019.10
|
7
7
|
Contact: support@dyspatch.io
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.9
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -34,14 +34,13 @@ describe 'LocalizationsApi' do
|
|
34
34
|
|
35
35
|
# unit tests for localizations_localization_id_get
|
36
36
|
# Get Localization Object by ID
|
37
|
-
# Returns a specific localization object with a matching ID
|
37
|
+
# Returns a specific localization object with a matching ID.
|
38
38
|
# @param localization_id A localization ID
|
39
|
+
# @param target_language The type of templating language to compile as. Should only be used for visual templates.
|
39
40
|
# @param [Hash] opts the optional parameters
|
40
|
-
# @option opts [String] :target_language The type of templating language to compile as. Should only be used for visual templates.
|
41
|
-
# @option opts [String] :accept A version of the API that should be used for the request. For example, to use version "2019.03", set the value to "application/vnd.dyspatch.2019.03+json"
|
42
41
|
# @return [LocalizationRead]
|
43
42
|
describe 'localizations_localization_id_get test' do
|
44
|
-
it
|
43
|
+
it 'should work' do
|
45
44
|
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
46
45
|
end
|
47
46
|
end
|