1 /**
2  * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3  * SPDX-License-Identifier: Apache-2.0.
4  */
5 
6 #pragma once
7 #include <aws/pinpoint/Pinpoint_EXPORTS.h>
8 #include <aws/pinpoint/PinpointRequest.h>
9 #include <aws/core/utils/memory/stl/AWSString.h>
10 #include <utility>
11 
12 namespace Aws
13 {
14 namespace Http
15 {
16     class URI;
17 } //namespace Http
18 namespace Pinpoint
19 {
20 namespace Model
21 {
22 
23   /**
24    */
25   class AWS_PINPOINT_API GetPushTemplateRequest : public PinpointRequest
26   {
27   public:
28     GetPushTemplateRequest();
29 
30     // Service request name is the Operation name which will send this request out,
31     // each operation should has unique request name, so that we can get operation's name from this request.
32     // Note: this is not true for response, multiple operations may have the same response name,
33     // so we can not get operation's name from response.
GetServiceRequestName()34     inline virtual const char* GetServiceRequestName() const override { return "GetPushTemplate"; }
35 
36     Aws::String SerializePayload() const override;
37 
38     void AddQueryStringParameters(Aws::Http::URI& uri) const override;
39 
40 
41     /**
42      * <p>The name of the message template. A template name must start with an
43      * alphanumeric character and can contain a maximum of 128 characters. The
44      * characters can be alphanumeric characters, underscores (_), or hyphens (-).
45      * Template names are case sensitive.</p>
46      */
GetTemplateName()47     inline const Aws::String& GetTemplateName() const{ return m_templateName; }
48 
49     /**
50      * <p>The name of the message template. A template name must start with an
51      * alphanumeric character and can contain a maximum of 128 characters. The
52      * characters can be alphanumeric characters, underscores (_), or hyphens (-).
53      * Template names are case sensitive.</p>
54      */
TemplateNameHasBeenSet()55     inline bool TemplateNameHasBeenSet() const { return m_templateNameHasBeenSet; }
56 
57     /**
58      * <p>The name of the message template. A template name must start with an
59      * alphanumeric character and can contain a maximum of 128 characters. The
60      * characters can be alphanumeric characters, underscores (_), or hyphens (-).
61      * Template names are case sensitive.</p>
62      */
SetTemplateName(const Aws::String & value)63     inline void SetTemplateName(const Aws::String& value) { m_templateNameHasBeenSet = true; m_templateName = value; }
64 
65     /**
66      * <p>The name of the message template. A template name must start with an
67      * alphanumeric character and can contain a maximum of 128 characters. The
68      * characters can be alphanumeric characters, underscores (_), or hyphens (-).
69      * Template names are case sensitive.</p>
70      */
SetTemplateName(Aws::String && value)71     inline void SetTemplateName(Aws::String&& value) { m_templateNameHasBeenSet = true; m_templateName = std::move(value); }
72 
73     /**
74      * <p>The name of the message template. A template name must start with an
75      * alphanumeric character and can contain a maximum of 128 characters. The
76      * characters can be alphanumeric characters, underscores (_), or hyphens (-).
77      * Template names are case sensitive.</p>
78      */
SetTemplateName(const char * value)79     inline void SetTemplateName(const char* value) { m_templateNameHasBeenSet = true; m_templateName.assign(value); }
80 
81     /**
82      * <p>The name of the message template. A template name must start with an
83      * alphanumeric character and can contain a maximum of 128 characters. The
84      * characters can be alphanumeric characters, underscores (_), or hyphens (-).
85      * Template names are case sensitive.</p>
86      */
WithTemplateName(const Aws::String & value)87     inline GetPushTemplateRequest& WithTemplateName(const Aws::String& value) { SetTemplateName(value); return *this;}
88 
89     /**
90      * <p>The name of the message template. A template name must start with an
91      * alphanumeric character and can contain a maximum of 128 characters. The
92      * characters can be alphanumeric characters, underscores (_), or hyphens (-).
93      * Template names are case sensitive.</p>
94      */
WithTemplateName(Aws::String && value)95     inline GetPushTemplateRequest& WithTemplateName(Aws::String&& value) { SetTemplateName(std::move(value)); return *this;}
96 
97     /**
98      * <p>The name of the message template. A template name must start with an
99      * alphanumeric character and can contain a maximum of 128 characters. The
100      * characters can be alphanumeric characters, underscores (_), or hyphens (-).
101      * Template names are case sensitive.</p>
102      */
WithTemplateName(const char * value)103     inline GetPushTemplateRequest& WithTemplateName(const char* value) { SetTemplateName(value); return *this;}
104 
105 
106     /**
107      * <p>The unique identifier for the version of the message template to update,
108      * retrieve information about, or delete. To retrieve identifiers and other
109      * information for all the versions of a template, use the <link
110      * linkend="templates-template-name-template-type-versions">Template
111      * Versions</link> resource.</p> <p>If specified, this value must match the
112      * identifier for an existing template version. If specified for an update
113      * operation, this value must match the identifier for the latest existing version
114      * of the template. This restriction helps ensure that race conditions don't
115      * occur.</p> <p>If you don't specify a value for this parameter, Amazon Pinpoint
116      * does the following:</p> <ul><li><p>For a get operation, retrieves information
117      * about the active version of the template.</p></li> <li><p>For an update
118      * operation, saves the updates to (overwrites) the latest existing version of the
119      * template, if the create-new-version parameter isn't used or is set to
120      * false.</p></li> <li><p>For a delete operation, deletes the template, including
121      * all versions of the template.</p></li></ul>
122      */
GetVersion()123     inline const Aws::String& GetVersion() const{ return m_version; }
124 
125     /**
126      * <p>The unique identifier for the version of the message template to update,
127      * retrieve information about, or delete. To retrieve identifiers and other
128      * information for all the versions of a template, use the <link
129      * linkend="templates-template-name-template-type-versions">Template
130      * Versions</link> resource.</p> <p>If specified, this value must match the
131      * identifier for an existing template version. If specified for an update
132      * operation, this value must match the identifier for the latest existing version
133      * of the template. This restriction helps ensure that race conditions don't
134      * occur.</p> <p>If you don't specify a value for this parameter, Amazon Pinpoint
135      * does the following:</p> <ul><li><p>For a get operation, retrieves information
136      * about the active version of the template.</p></li> <li><p>For an update
137      * operation, saves the updates to (overwrites) the latest existing version of the
138      * template, if the create-new-version parameter isn't used or is set to
139      * false.</p></li> <li><p>For a delete operation, deletes the template, including
140      * all versions of the template.</p></li></ul>
141      */
VersionHasBeenSet()142     inline bool VersionHasBeenSet() const { return m_versionHasBeenSet; }
143 
144     /**
145      * <p>The unique identifier for the version of the message template to update,
146      * retrieve information about, or delete. To retrieve identifiers and other
147      * information for all the versions of a template, use the <link
148      * linkend="templates-template-name-template-type-versions">Template
149      * Versions</link> resource.</p> <p>If specified, this value must match the
150      * identifier for an existing template version. If specified for an update
151      * operation, this value must match the identifier for the latest existing version
152      * of the template. This restriction helps ensure that race conditions don't
153      * occur.</p> <p>If you don't specify a value for this parameter, Amazon Pinpoint
154      * does the following:</p> <ul><li><p>For a get operation, retrieves information
155      * about the active version of the template.</p></li> <li><p>For an update
156      * operation, saves the updates to (overwrites) the latest existing version of the
157      * template, if the create-new-version parameter isn't used or is set to
158      * false.</p></li> <li><p>For a delete operation, deletes the template, including
159      * all versions of the template.</p></li></ul>
160      */
SetVersion(const Aws::String & value)161     inline void SetVersion(const Aws::String& value) { m_versionHasBeenSet = true; m_version = value; }
162 
163     /**
164      * <p>The unique identifier for the version of the message template to update,
165      * retrieve information about, or delete. To retrieve identifiers and other
166      * information for all the versions of a template, use the <link
167      * linkend="templates-template-name-template-type-versions">Template
168      * Versions</link> resource.</p> <p>If specified, this value must match the
169      * identifier for an existing template version. If specified for an update
170      * operation, this value must match the identifier for the latest existing version
171      * of the template. This restriction helps ensure that race conditions don't
172      * occur.</p> <p>If you don't specify a value for this parameter, Amazon Pinpoint
173      * does the following:</p> <ul><li><p>For a get operation, retrieves information
174      * about the active version of the template.</p></li> <li><p>For an update
175      * operation, saves the updates to (overwrites) the latest existing version of the
176      * template, if the create-new-version parameter isn't used or is set to
177      * false.</p></li> <li><p>For a delete operation, deletes the template, including
178      * all versions of the template.</p></li></ul>
179      */
SetVersion(Aws::String && value)180     inline void SetVersion(Aws::String&& value) { m_versionHasBeenSet = true; m_version = std::move(value); }
181 
182     /**
183      * <p>The unique identifier for the version of the message template to update,
184      * retrieve information about, or delete. To retrieve identifiers and other
185      * information for all the versions of a template, use the <link
186      * linkend="templates-template-name-template-type-versions">Template
187      * Versions</link> resource.</p> <p>If specified, this value must match the
188      * identifier for an existing template version. If specified for an update
189      * operation, this value must match the identifier for the latest existing version
190      * of the template. This restriction helps ensure that race conditions don't
191      * occur.</p> <p>If you don't specify a value for this parameter, Amazon Pinpoint
192      * does the following:</p> <ul><li><p>For a get operation, retrieves information
193      * about the active version of the template.</p></li> <li><p>For an update
194      * operation, saves the updates to (overwrites) the latest existing version of the
195      * template, if the create-new-version parameter isn't used or is set to
196      * false.</p></li> <li><p>For a delete operation, deletes the template, including
197      * all versions of the template.</p></li></ul>
198      */
SetVersion(const char * value)199     inline void SetVersion(const char* value) { m_versionHasBeenSet = true; m_version.assign(value); }
200 
201     /**
202      * <p>The unique identifier for the version of the message template to update,
203      * retrieve information about, or delete. To retrieve identifiers and other
204      * information for all the versions of a template, use the <link
205      * linkend="templates-template-name-template-type-versions">Template
206      * Versions</link> resource.</p> <p>If specified, this value must match the
207      * identifier for an existing template version. If specified for an update
208      * operation, this value must match the identifier for the latest existing version
209      * of the template. This restriction helps ensure that race conditions don't
210      * occur.</p> <p>If you don't specify a value for this parameter, Amazon Pinpoint
211      * does the following:</p> <ul><li><p>For a get operation, retrieves information
212      * about the active version of the template.</p></li> <li><p>For an update
213      * operation, saves the updates to (overwrites) the latest existing version of the
214      * template, if the create-new-version parameter isn't used or is set to
215      * false.</p></li> <li><p>For a delete operation, deletes the template, including
216      * all versions of the template.</p></li></ul>
217      */
WithVersion(const Aws::String & value)218     inline GetPushTemplateRequest& WithVersion(const Aws::String& value) { SetVersion(value); return *this;}
219 
220     /**
221      * <p>The unique identifier for the version of the message template to update,
222      * retrieve information about, or delete. To retrieve identifiers and other
223      * information for all the versions of a template, use the <link
224      * linkend="templates-template-name-template-type-versions">Template
225      * Versions</link> resource.</p> <p>If specified, this value must match the
226      * identifier for an existing template version. If specified for an update
227      * operation, this value must match the identifier for the latest existing version
228      * of the template. This restriction helps ensure that race conditions don't
229      * occur.</p> <p>If you don't specify a value for this parameter, Amazon Pinpoint
230      * does the following:</p> <ul><li><p>For a get operation, retrieves information
231      * about the active version of the template.</p></li> <li><p>For an update
232      * operation, saves the updates to (overwrites) the latest existing version of the
233      * template, if the create-new-version parameter isn't used or is set to
234      * false.</p></li> <li><p>For a delete operation, deletes the template, including
235      * all versions of the template.</p></li></ul>
236      */
WithVersion(Aws::String && value)237     inline GetPushTemplateRequest& WithVersion(Aws::String&& value) { SetVersion(std::move(value)); return *this;}
238 
239     /**
240      * <p>The unique identifier for the version of the message template to update,
241      * retrieve information about, or delete. To retrieve identifiers and other
242      * information for all the versions of a template, use the <link
243      * linkend="templates-template-name-template-type-versions">Template
244      * Versions</link> resource.</p> <p>If specified, this value must match the
245      * identifier for an existing template version. If specified for an update
246      * operation, this value must match the identifier for the latest existing version
247      * of the template. This restriction helps ensure that race conditions don't
248      * occur.</p> <p>If you don't specify a value for this parameter, Amazon Pinpoint
249      * does the following:</p> <ul><li><p>For a get operation, retrieves information
250      * about the active version of the template.</p></li> <li><p>For an update
251      * operation, saves the updates to (overwrites) the latest existing version of the
252      * template, if the create-new-version parameter isn't used or is set to
253      * false.</p></li> <li><p>For a delete operation, deletes the template, including
254      * all versions of the template.</p></li></ul>
255      */
WithVersion(const char * value)256     inline GetPushTemplateRequest& WithVersion(const char* value) { SetVersion(value); return *this;}
257 
258   private:
259 
260     Aws::String m_templateName;
261     bool m_templateNameHasBeenSet;
262 
263     Aws::String m_version;
264     bool m_versionHasBeenSet;
265   };
266 
267 } // namespace Model
268 } // namespace Pinpoint
269 } // namespace Aws
270