blob: 79fcc892516c5224bb8065b3e82dbac16a4c3e0b [file] [log] [blame]
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001<html><body>
2<style>
3
4body, 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
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, 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
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070075<h1><a href="safebrowsing_v4.html">Safe Browsing API</a> . <a href="safebrowsing_v4.encodedUpdates.html">encodedUpdates</a></h1>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040076<h2>Instance Methods</h2>
77<p class="toc_element">
Bu Sun Kim65020912020-05-20 12:08:20 -070078 <code><a href="#get">get(encodedRequest, clientId=None, clientVersion=None, x__xgafv=None)</a></code></p>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040079<p class="firstline"></p>
80<h3>Method Details</h3>
81<div class="method">
Bu Sun Kim65020912020-05-20 12:08:20 -070082 <code class="details" id="get">get(encodedRequest, clientId=None, clientVersion=None, x__xgafv=None)</code>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040083 <pre>
84
85Args:
86 encodedRequest: string, A serialized FetchThreatListUpdatesRequest proto. (required)
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040087 clientId: string, A client ID that uniquely identifies the client implementation of the Safe
88Browsing API.
Bu Sun Kim65020912020-05-20 12:08:20 -070089 clientVersion: string, The version of the client implementation.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040090 x__xgafv: string, V1 error format.
91 Allowed values
92 1 - v1 error format
93 2 - v2 error format
94
95Returns:
96 An object of the form:
97
98 {
Bu Sun Kim65020912020-05-20 12:08:20 -070099 &quot;listUpdateResponses&quot;: [ # The list updates requested by the clients.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400100 { # An update to an individual list.
Bu Sun Kim65020912020-05-20 12:08:20 -0700101 &quot;additions&quot;: [ # A set of entries to add to a local threat type&#x27;s list. Repeated to allow
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400102 # for a combination of compressed and raw data to be sent in a single
103 # response.
Bu Sun Kim65020912020-05-20 12:08:20 -0700104 { # A set of threats that should be added or removed from a client&#x27;s local
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400105 # database.
Bu Sun Kim65020912020-05-20 12:08:20 -0700106 &quot;compressionType&quot;: &quot;A String&quot;, # The compression type for the entries in this set.
107 &quot;riceIndices&quot;: { # The Rice-Golomb encoded data. Used for sending compressed 4-byte hashes or # The encoded local, lexicographically-sorted list indices, using a
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700108 # Golomb-Rice encoding. Used for sending compressed removal indices. The
109 # removal indices (uint32) are sorted in ascending order, then delta encoded
110 # and stored as encoded_data.
111 # compressed removal indices.
Bu Sun Kim65020912020-05-20 12:08:20 -0700112 &quot;firstValue&quot;: &quot;A String&quot;, # The offset of the first entry in the encoded data, or, if only a single
113 # integer was encoded, that single integer&#x27;s value. If the field is empty or
114 # missing, assume zero.
115 &quot;encodedData&quot;: &quot;A String&quot;, # The encoded deltas that are encoded using the Golomb-Rice coder.
116 &quot;numEntries&quot;: 42, # The number of entries that are delta encoded in the encoded data. If only a
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700117 # single integer was encoded, this will be zero and the single value will be
118 # stored in `first_value`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700119 &quot;riceParameter&quot;: 42, # The Golomb-Rice parameter, which is a number between 2 and 28. This field
120 # is missing (that is, zero) if `num_entries` is zero.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700121 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700122 &quot;rawIndices&quot;: { # A set of raw indices to remove from a local list. # The raw removal indices for a local list.
123 &quot;indices&quot;: [ # The indices to remove from a lexicographically-sorted local list.
124 42,
125 ],
126 },
127 &quot;rawHashes&quot;: { # The uncompressed threat entries in hash format of a particular prefix length. # The raw SHA256-formatted entries.
Dan O'Mearadd494642020-05-01 07:42:23 -0700128 # Hashes can be anywhere from 4 to 32 bytes in size. A large majority are 4
129 # bytes, but some hashes are lengthened if they collide with the hash of a
130 # popular URL.
131 #
132 # Used for sending ThreatEntrySet to clients that do not support compression,
133 # or when sending non-4-byte hashes to clients that do support compression.
Bu Sun Kim65020912020-05-20 12:08:20 -0700134 &quot;rawHashes&quot;: &quot;A String&quot;, # The hashes, in binary format, concatenated into one long string. Hashes are
Dan O'Mearadd494642020-05-01 07:42:23 -0700135 # sorted in lexicographic order. For JSON API users, hashes are
136 # base64-encoded.
Bu Sun Kim65020912020-05-20 12:08:20 -0700137 &quot;prefixSize&quot;: 42, # The number of bytes for each prefix encoded below. This field can be
138 # anywhere from 4 (shortest prefix) to 32 (full SHA256 hash).
139 },
140 &quot;riceHashes&quot;: { # The Rice-Golomb encoded data. Used for sending compressed 4-byte hashes or # The encoded 4-byte prefixes of SHA256-formatted entries, using a
141 # Golomb-Rice encoding. The hashes are converted to uint32, sorted in
142 # ascending order, then delta encoded and stored as encoded_data.
143 # compressed removal indices.
144 &quot;firstValue&quot;: &quot;A String&quot;, # The offset of the first entry in the encoded data, or, if only a single
145 # integer was encoded, that single integer&#x27;s value. If the field is empty or
146 # missing, assume zero.
147 &quot;encodedData&quot;: &quot;A String&quot;, # The encoded deltas that are encoded using the Golomb-Rice coder.
148 &quot;numEntries&quot;: 42, # The number of entries that are delta encoded in the encoded data. If only a
149 # single integer was encoded, this will be zero and the single value will be
150 # stored in `first_value`.
151 &quot;riceParameter&quot;: 42, # The Golomb-Rice parameter, which is a number between 2 and 28. This field
152 # is missing (that is, zero) if `num_entries` is zero.
Dan O'Mearadd494642020-05-01 07:42:23 -0700153 },
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400154 },
155 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700156 &quot;checksum&quot;: { # The expected state of a client&#x27;s local database. # The expected SHA256 hash of the client state; that is, of the sorted list
157 # of all hashes present in the database after applying the provided update.
158 # If the client state doesn&#x27;t match the expected state, the client must
159 # disregard this update and retry later.
160 &quot;sha256&quot;: &quot;A String&quot;, # The SHA256 hash of the client state; that is, of the sorted list of all
161 # hashes present in the database.
162 },
163 &quot;responseType&quot;: &quot;A String&quot;, # The type of response. This may indicate that an action is required by the
164 # client when the response is received.
165 &quot;threatType&quot;: &quot;A String&quot;, # The threat type for which data is returned.
166 &quot;removals&quot;: [ # A set of entries to remove from a local threat type&#x27;s list. In practice,
167 # this field is empty or contains exactly one ThreatEntrySet.
168 { # A set of threats that should be added or removed from a client&#x27;s local
169 # database.
170 &quot;compressionType&quot;: &quot;A String&quot;, # The compression type for the entries in this set.
171 &quot;riceIndices&quot;: { # The Rice-Golomb encoded data. Used for sending compressed 4-byte hashes or # The encoded local, lexicographically-sorted list indices, using a
172 # Golomb-Rice encoding. Used for sending compressed removal indices. The
173 # removal indices (uint32) are sorted in ascending order, then delta encoded
174 # and stored as encoded_data.
175 # compressed removal indices.
176 &quot;firstValue&quot;: &quot;A String&quot;, # The offset of the first entry in the encoded data, or, if only a single
177 # integer was encoded, that single integer&#x27;s value. If the field is empty or
178 # missing, assume zero.
179 &quot;encodedData&quot;: &quot;A String&quot;, # The encoded deltas that are encoded using the Golomb-Rice coder.
180 &quot;numEntries&quot;: 42, # The number of entries that are delta encoded in the encoded data. If only a
181 # single integer was encoded, this will be zero and the single value will be
182 # stored in `first_value`.
183 &quot;riceParameter&quot;: 42, # The Golomb-Rice parameter, which is a number between 2 and 28. This field
184 # is missing (that is, zero) if `num_entries` is zero.
185 },
186 &quot;rawIndices&quot;: { # A set of raw indices to remove from a local list. # The raw removal indices for a local list.
187 &quot;indices&quot;: [ # The indices to remove from a lexicographically-sorted local list.
188 42,
189 ],
190 },
191 &quot;rawHashes&quot;: { # The uncompressed threat entries in hash format of a particular prefix length. # The raw SHA256-formatted entries.
192 # Hashes can be anywhere from 4 to 32 bytes in size. A large majority are 4
193 # bytes, but some hashes are lengthened if they collide with the hash of a
194 # popular URL.
195 #
196 # Used for sending ThreatEntrySet to clients that do not support compression,
197 # or when sending non-4-byte hashes to clients that do support compression.
198 &quot;rawHashes&quot;: &quot;A String&quot;, # The hashes, in binary format, concatenated into one long string. Hashes are
199 # sorted in lexicographic order. For JSON API users, hashes are
200 # base64-encoded.
201 &quot;prefixSize&quot;: 42, # The number of bytes for each prefix encoded below. This field can be
202 # anywhere from 4 (shortest prefix) to 32 (full SHA256 hash).
203 },
204 &quot;riceHashes&quot;: { # The Rice-Golomb encoded data. Used for sending compressed 4-byte hashes or # The encoded 4-byte prefixes of SHA256-formatted entries, using a
205 # Golomb-Rice encoding. The hashes are converted to uint32, sorted in
206 # ascending order, then delta encoded and stored as encoded_data.
207 # compressed removal indices.
208 &quot;firstValue&quot;: &quot;A String&quot;, # The offset of the first entry in the encoded data, or, if only a single
209 # integer was encoded, that single integer&#x27;s value. If the field is empty or
210 # missing, assume zero.
211 &quot;encodedData&quot;: &quot;A String&quot;, # The encoded deltas that are encoded using the Golomb-Rice coder.
212 &quot;numEntries&quot;: 42, # The number of entries that are delta encoded in the encoded data. If only a
213 # single integer was encoded, this will be zero and the single value will be
214 # stored in `first_value`.
215 &quot;riceParameter&quot;: 42, # The Golomb-Rice parameter, which is a number between 2 and 28. This field
216 # is missing (that is, zero) if `num_entries` is zero.
217 },
218 },
219 ],
220 &quot;newClientState&quot;: &quot;A String&quot;, # The new client state, in encrypted format. Opaque to clients.
221 &quot;platformType&quot;: &quot;A String&quot;, # The platform type for which data is returned.
222 &quot;threatEntryType&quot;: &quot;A String&quot;, # The format of the threats.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400223 },
224 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700225 &quot;minimumWaitDuration&quot;: &quot;A String&quot;, # The minimum duration the client must wait before issuing any update
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400226 # request. If this field is not set clients may update as soon as they want.
227 }</pre>
228</div>
229
230</body></html>