Debian Codegraph @

docs/dyn/health_v4.projects.subscribers.subscriptions.html

raw
1 <html><body>
2 <style>
3
4 body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13 }
14
15 body {
16 font-size: 13px;
17 padding: 1em;
18 }
19
20 h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23 }
24
25 h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28 }
29
30 h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34 }
35
36 pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39 }
40
41 pre {
42 margin-top: 0.5em;
43 }
44
45 h1, h2, h3, p {
46 font-family: Arial, sans serif;
47 }
48
49 h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51 }
52
53 .toc_element {
54 margin-top: 0.5em;
55 }
56
57 .firstline {
58 margin-left: 2 em;
59 }
60
61 .method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66 }
67
68 .details {
69 font-weight: bold;
70 font-size: 14px;
71 }
72
73 </style>
74
75 <h1><a href="health_v4.html">Google Health API</a> . <a href="health_v4.projects.html">projects</a> . <a href="health_v4.projects.subscribers.html">subscribers</a> . <a href="health_v4.projects.subscribers.subscriptions.html">subscriptions</a></h1>
76 <h2>Instance Methods</h2>
77 <p class="toc_element">
78 <code><a href="#close">close()</a></code></p>
79 <p class="firstline">Close httplib2 connections.</p>
80 <p class="toc_element">
81 <code><a href="#create">create(parent, body=None, subscriptionId=None, x__xgafv=None)</a></code></p>
82 <p class="firstline">Creates a subscription for a specific user to a specific subscriber. This method requires the subscriber to have a `SubscriptionCreatePolicy` set to `MANUAL` for the given data types.</p>
83 <p class="toc_element">
84 <code><a href="#delete">delete(name, x__xgafv=None)</a></code></p>
85 <p class="firstline">Deletes a specific user subscription, stopping notifications for this user to this subscriber.</p>
86 <p class="toc_element">
87 <code><a href="#list">list(parent, filter=None, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p>
88 <p class="firstline">Lists all active subscriptions for a given subscriber. This can be filtered, for example, by user or data type.</p>
89 <p class="toc_element">
90 <code><a href="#list_next">list_next()</a></code></p>
91 <p class="firstline">Retrieves the next page of results.</p>
92 <p class="toc_element">
93 <code><a href="#patch">patch(name, body=None, updateMask=None, x__xgafv=None)</a></code></p>
94 <p class="firstline">Updates the data types for an existing user subscription.</p>
95 <h3>Method Details</h3>
96 <div class="method">
97 <code class="details" id="close">close()</code>
98 <pre>Close httplib2 connections.</pre>
99 </div>
100
101 <div class="method">
102 <code class="details" id="create">create(parent, body=None, subscriptionId=None, x__xgafv=None)</code>
103 <pre>Creates a subscription for a specific user to a specific subscriber. This method requires the subscriber to have a `SubscriptionCreatePolicy` set to `MANUAL` for the given data types.
104
105 Args:
106 parent: string, Required. The parent subscriber. Format: projects/{project}/subscribers/{subscriber} The {subscriber} ID is user-settable (4-36 characters, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) if provided during creation, or system-generated otherwise. (required)
107 body: object, The request body.
108 The object takes the form of:
109
110 { # Payload for creating a subscription.
111 &quot;dataTypes&quot;: [ # Optional. Data types subscribed to.
112 &quot;A String&quot;,
113 ],
114 &quot;user&quot;: &quot;A String&quot;, # Required. Immutable. The resource name of the user for whom this subscription is active. Format: `users/{user}` where `{user}` is the public `healthUserId` as returned by the `GetIdentity` action in the profile PAPI (see `google.devicesandservices.health.v4main.HealthProfileService.GetIdentity`).
115 }
116
117 subscriptionId: string, Optional. The {subscription_id} is user-settable (4-36 chars, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) or system-generated otherwise. If provided, the ID must be unique within the parent subscriber.
118 x__xgafv: string, V1 error format.
119 Allowed values
120 1 - v1 error format
121 2 - v2 error format
122
123 Returns:
124 An object of the form:
125
126 { # A subscription to a data collection for a specific user, to be delivered to a subscriber.
127 &quot;dataTypes&quot;: [ # Optional. Data types subscribed to. A subscriber will only receive notifications for data types that are declared here. A subscription can only subscribe to the data types of the subscriber. The values should be in the format &quot;users/{health_user_id}/dataTypes/{data_type}&quot; where `{data_type}` is one of &quot;altitude&quot;, &quot;distance&quot;, &quot;floors&quot;, &quot;sleep&quot;, &quot;steps&quot;, &quot;weight&quot;.
128 &quot;A String&quot;,
129 ],
130 &quot;name&quot;: &quot;A String&quot;, # Identifier. The resource name of the Subscription. Format: `projects/{project}/subscribers/{subscriber}/subscriptions/{subscription}` Example: `projects/my-project/subscribers/my-subscriber-123/subscriptions/my-subscription-456` The {project} ID is mandatory (6-30 characters, matching /a-z{6,30}/) The {subscriber} ID is user-settable (4-36 characters, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) if provided during creation, or system-generated otherwise. The {subscription} ID is user-settable (4-36 chars, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) or system-generated otherwise.
131 &quot;user&quot;: &quot;A String&quot;, # Immutable. The resource name of the user for whom this subscription is active. Format: `users/{user}` where `{user}` is the public `healthUserId` as returned by the `GetIdentity` action in the profile PAPI (see `google.devicesandservices.health.v4main.HealthProfileService.GetIdentity`).
132 }</pre>
133 </div>
134
135 <div class="method">
136 <code class="details" id="delete">delete(name, x__xgafv=None)</code>
137 <pre>Deletes a specific user subscription, stopping notifications for this user to this subscriber.
138
139 Args:
140 name: string, Required. The resource name of the subscription to delete. Format: `projects/{project}/subscribers/{subscriber}/subscriptions/{subscription}` Example: `projects/my-project/subscribers/my-subscriber-123/subscriptions/my-subscription-456` The {subscriber} ID is user-settable (4-36 characters, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) if provided during creation, or system-generated otherwise. The {subscription} ID is user-settable (4-36 characters, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) or system-generated if not provided during creation. (required)
141 x__xgafv: string, V1 error format.
142 Allowed values
143 1 - v1 error format
144 2 - v2 error format
145
146 Returns:
147 An object of the form:
148
149 { # A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }
150 }</pre>
151 </div>
152
153 <div class="method">
154 <code class="details" id="list">list(parent, filter=None, pageSize=None, pageToken=None, x__xgafv=None)</code>
155 <pre>Lists all active subscriptions for a given subscriber. This can be filtered, for example, by user or data type.
156
157 Args:
158 parent: string, Required. The parent subscriber. Format: projects/{project}/subscribers/{subscriber} The {subscriber} ID is user-settable (4-36 characters, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) if provided during creation, or system-generated otherwise. (required)
159 filter: string, Optional. A filter to apply to the list of subscriptions. The filter syntax is described in https://google.aip.dev/160. The filter can be applied to the following fields: - `user` - `data_type` The `user` identifier (e.g., `user1` in `users/user1`) refers to the public `health_user_id` Example: user = &quot;users/user1&quot; Example: user = &quot;users/user1&quot; OR user = &quot;users/user2&quot; Example: user = &quot;users/user1&quot; AND (data_type = &quot;sleep&quot; OR data_type = &quot;weight&quot;)
160 pageSize: integer, Optional. The maximum number of subscriptions to return. The service may return fewer than this value. If unspecified, at most 50 subscriptions will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
161 pageToken: string, Optional. A page token, received from a previous `ListSubscriptions` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListSubscriptions` must match the call that provided the page token.
162 x__xgafv: string, V1 error format.
163 Allowed values
164 1 - v1 error format
165 2 - v2 error format
166
167 Returns:
168 An object of the form:
169
170 { # Response message for ListSubscriptions.
171 &quot;nextPageToken&quot;: &quot;A String&quot;, # A token, which can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.
172 &quot;subscriptions&quot;: [ # The subscriptions from the specified subscriber.
173 { # A subscription to a data collection for a specific user, to be delivered to a subscriber.
174 &quot;dataTypes&quot;: [ # Optional. Data types subscribed to. A subscriber will only receive notifications for data types that are declared here. A subscription can only subscribe to the data types of the subscriber. The values should be in the format &quot;users/{health_user_id}/dataTypes/{data_type}&quot; where `{data_type}` is one of &quot;altitude&quot;, &quot;distance&quot;, &quot;floors&quot;, &quot;sleep&quot;, &quot;steps&quot;, &quot;weight&quot;.
175 &quot;A String&quot;,
176 ],
177 &quot;name&quot;: &quot;A String&quot;, # Identifier. The resource name of the Subscription. Format: `projects/{project}/subscribers/{subscriber}/subscriptions/{subscription}` Example: `projects/my-project/subscribers/my-subscriber-123/subscriptions/my-subscription-456` The {project} ID is mandatory (6-30 characters, matching /a-z{6,30}/) The {subscriber} ID is user-settable (4-36 characters, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) if provided during creation, or system-generated otherwise. The {subscription} ID is user-settable (4-36 chars, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) or system-generated otherwise.
178 &quot;user&quot;: &quot;A String&quot;, # Immutable. The resource name of the user for whom this subscription is active. Format: `users/{user}` where `{user}` is the public `healthUserId` as returned by the `GetIdentity` action in the profile PAPI (see `google.devicesandservices.health.v4main.HealthProfileService.GetIdentity`).
179 },
180 ],
181 }</pre>
182 </div>
183
184 <div class="method">
185 <code class="details" id="list_next">list_next()</code>
186 <pre>Retrieves the next page of results.
187
188 Args:
189 previous_request: The request for the previous page. (required)
190 previous_response: The response from the request for the previous page. (required)
191
192 Returns:
193 A request object that you can call &#x27;execute()&#x27; on to request the next
194 page. Returns None if there are no more items in the collection.
195 </pre>
196 </div>
197
198 <div class="method">
199 <code class="details" id="patch">patch(name, body=None, updateMask=None, x__xgafv=None)</code>
200 <pre>Updates the data types for an existing user subscription.
201
202 Args:
203 name: string, Identifier. The resource name of the Subscription. Format: `projects/{project}/subscribers/{subscriber}/subscriptions/{subscription}` Example: `projects/my-project/subscribers/my-subscriber-123/subscriptions/my-subscription-456` The {project} ID is mandatory (6-30 characters, matching /a-z{6,30}/) The {subscriber} ID is user-settable (4-36 characters, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) if provided during creation, or system-generated otherwise. The {subscription} ID is user-settable (4-36 chars, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) or system-generated otherwise. (required)
204 body: object, The request body.
205 The object takes the form of:
206
207 { # A subscription to a data collection for a specific user, to be delivered to a subscriber.
208 &quot;dataTypes&quot;: [ # Optional. Data types subscribed to. A subscriber will only receive notifications for data types that are declared here. A subscription can only subscribe to the data types of the subscriber. The values should be in the format &quot;users/{health_user_id}/dataTypes/{data_type}&quot; where `{data_type}` is one of &quot;altitude&quot;, &quot;distance&quot;, &quot;floors&quot;, &quot;sleep&quot;, &quot;steps&quot;, &quot;weight&quot;.
209 &quot;A String&quot;,
210 ],
211 &quot;name&quot;: &quot;A String&quot;, # Identifier. The resource name of the Subscription. Format: `projects/{project}/subscribers/{subscriber}/subscriptions/{subscription}` Example: `projects/my-project/subscribers/my-subscriber-123/subscriptions/my-subscription-456` The {project} ID is mandatory (6-30 characters, matching /a-z{6,30}/) The {subscriber} ID is user-settable (4-36 characters, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) if provided during creation, or system-generated otherwise. The {subscription} ID is user-settable (4-36 chars, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) or system-generated otherwise.
212 &quot;user&quot;: &quot;A String&quot;, # Immutable. The resource name of the user for whom this subscription is active. Format: `users/{user}` where `{user}` is the public `healthUserId` as returned by the `GetIdentity` action in the profile PAPI (see `google.devicesandservices.health.v4main.HealthProfileService.GetIdentity`).
213 }
214
215 updateMask: string, Optional. The list of fields to update.
216 x__xgafv: string, V1 error format.
217 Allowed values
218 1 - v1 error format
219 2 - v2 error format
220
221 Returns:
222 An object of the form:
223
224 { # A subscription to a data collection for a specific user, to be delivered to a subscriber.
225 &quot;dataTypes&quot;: [ # Optional. Data types subscribed to. A subscriber will only receive notifications for data types that are declared here. A subscription can only subscribe to the data types of the subscriber. The values should be in the format &quot;users/{health_user_id}/dataTypes/{data_type}&quot; where `{data_type}` is one of &quot;altitude&quot;, &quot;distance&quot;, &quot;floors&quot;, &quot;sleep&quot;, &quot;steps&quot;, &quot;weight&quot;.
226 &quot;A String&quot;,
227 ],
228 &quot;name&quot;: &quot;A String&quot;, # Identifier. The resource name of the Subscription. Format: `projects/{project}/subscribers/{subscriber}/subscriptions/{subscription}` Example: `projects/my-project/subscribers/my-subscriber-123/subscriptions/my-subscription-456` The {project} ID is mandatory (6-30 characters, matching /a-z{6,30}/) The {subscriber} ID is user-settable (4-36 characters, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) if provided during creation, or system-generated otherwise. The {subscription} ID is user-settable (4-36 chars, matching /[a-z]([a-z0-9-]{2,34}[a-z0-9])/) or system-generated otherwise.
229 &quot;user&quot;: &quot;A String&quot;, # Immutable. The resource name of the user for whom this subscription is active. Format: `users/{user}` where `{user}` is the public `healthUserId` as returned by the `GetIdentity` action in the profile PAPI (see `google.devicesandservices.health.v4main.HealthProfileService.GetIdentity`).
230 }</pre>
231 </div>
232
233 </body></html>