├── .gitignore
├── LICENSE
├── README.md
├── cmd
├── cmd.go
├── conf.go
├── flush.go
└── server.go
├── go.mod
├── go.sum
├── internal
├── api
│ ├── config
│ │ └── config.go
│ ├── engine.go
│ ├── methods
│ │ ├── deleteMessages.go
│ │ ├── getChatPhoto.go
│ │ ├── getMessages.go
│ │ ├── getProfilePhotos.go
│ │ └── resolveUsername.go
│ ├── request
│ │ └── request.go
│ ├── response
│ │ ├── error.go
│ │ └── result.go
│ ├── server
│ │ ├── handler.go
│ │ └── server.go
│ └── types
│ │ └── chat.go
└── helpers
│ ├── helpers.go
│ ├── photos
│ └── photos.go
│ └── telegraph
│ └── init.go
├── main.go
└── pkg
└── elide
├── conn.go
├── errors.go
├── methods.go
└── types.go
/.gitignore:
--------------------------------------------------------------------------------
1 | elide-tg.session
2 | elide.yaml
3 | elide.bin
4 | elide
5 | downloads/
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | GNU AFFERO GENERAL PUBLIC LICENSE
2 | Version 3, 19 November 2007
3 |
4 | Copyright (C) 2007 Free Software Foundation, Inc.
5 | Everyone is permitted to copy and distribute verbatim copies
6 | of this license document, but changing it is not allowed.
7 |
8 | Preamble
9 |
10 | The GNU Affero General Public License is a free, copyleft license for
11 | software and other kinds of works, specifically designed to ensure
12 | cooperation with the community in the case of network server software.
13 |
14 | The licenses for most software and other practical works are designed
15 | to take away your freedom to share and change the works. By contrast,
16 | our General Public Licenses are intended to guarantee your freedom to
17 | share and change all versions of a program--to make sure it remains free
18 | software for all its users.
19 |
20 | When we speak of free software, we are referring to freedom, not
21 | price. Our General Public Licenses are designed to make sure that you
22 | have the freedom to distribute copies of free software (and charge for
23 | them if you wish), that you receive source code or can get it if you
24 | want it, that you can change the software or use pieces of it in new
25 | free programs, and that you know you can do these things.
26 |
27 | Developers that use our General Public Licenses protect your rights
28 | with two steps: (1) assert copyright on the software, and (2) offer
29 | you this License which gives you legal permission to copy, distribute
30 | and/or modify the software.
31 |
32 | A secondary benefit of defending all users' freedom is that
33 | improvements made in alternate versions of the program, if they
34 | receive widespread use, become available for other developers to
35 | incorporate. Many developers of free software are heartened and
36 | encouraged by the resulting cooperation. However, in the case of
37 | software used on network servers, this result may fail to come about.
38 | The GNU General Public License permits making a modified version and
39 | letting the public access it on a server without ever releasing its
40 | source code to the public.
41 |
42 | The GNU Affero General Public License is designed specifically to
43 | ensure that, in such cases, the modified source code becomes available
44 | to the community. It requires the operator of a network server to
45 | provide the source code of the modified version running there to the
46 | users of that server. Therefore, public use of a modified version, on
47 | a publicly accessible server, gives the public access to the source
48 | code of the modified version.
49 |
50 | An older license, called the Affero General Public License and
51 | published by Affero, was designed to accomplish similar goals. This is
52 | a different license, not a version of the Affero GPL, but Affero has
53 | released a new version of the Affero GPL which permits relicensing under
54 | this license.
55 |
56 | The precise terms and conditions for copying, distribution and
57 | modification follow.
58 |
59 | TERMS AND CONDITIONS
60 |
61 | 0. Definitions.
62 |
63 | "This License" refers to version 3 of the GNU Affero General Public License.
64 |
65 | "Copyright" also means copyright-like laws that apply to other kinds of
66 | works, such as semiconductor masks.
67 |
68 | "The Program" refers to any copyrightable work licensed under this
69 | License. Each licensee is addressed as "you". "Licensees" and
70 | "recipients" may be individuals or organizations.
71 |
72 | To "modify" a work means to copy from or adapt all or part of the work
73 | in a fashion requiring copyright permission, other than the making of an
74 | exact copy. The resulting work is called a "modified version" of the
75 | earlier work or a work "based on" the earlier work.
76 |
77 | A "covered work" means either the unmodified Program or a work based
78 | on the Program.
79 |
80 | To "propagate" a work means to do anything with it that, without
81 | permission, would make you directly or secondarily liable for
82 | infringement under applicable copyright law, except executing it on a
83 | computer or modifying a private copy. Propagation includes copying,
84 | distribution (with or without modification), making available to the
85 | public, and in some countries other activities as well.
86 |
87 | To "convey" a work means any kind of propagation that enables other
88 | parties to make or receive copies. Mere interaction with a user through
89 | a computer network, with no transfer of a copy, is not conveying.
90 |
91 | An interactive user interface displays "Appropriate Legal Notices"
92 | to the extent that it includes a convenient and prominently visible
93 | feature that (1) displays an appropriate copyright notice, and (2)
94 | tells the user that there is no warranty for the work (except to the
95 | extent that warranties are provided), that licensees may convey the
96 | work under this License, and how to view a copy of this License. If
97 | the interface presents a list of user commands or options, such as a
98 | menu, a prominent item in the list meets this criterion.
99 |
100 | 1. Source Code.
101 |
102 | The "source code" for a work means the preferred form of the work
103 | for making modifications to it. "Object code" means any non-source
104 | form of a work.
105 |
106 | A "Standard Interface" means an interface that either is an official
107 | standard defined by a recognized standards body, or, in the case of
108 | interfaces specified for a particular programming language, one that
109 | is widely used among developers working in that language.
110 |
111 | The "System Libraries" of an executable work include anything, other
112 | than the work as a whole, that (a) is included in the normal form of
113 | packaging a Major Component, but which is not part of that Major
114 | Component, and (b) serves only to enable use of the work with that
115 | Major Component, or to implement a Standard Interface for which an
116 | implementation is available to the public in source code form. A
117 | "Major Component", in this context, means a major essential component
118 | (kernel, window system, and so on) of the specific operating system
119 | (if any) on which the executable work runs, or a compiler used to
120 | produce the work, or an object code interpreter used to run it.
121 |
122 | The "Corresponding Source" for a work in object code form means all
123 | the source code needed to generate, install, and (for an executable
124 | work) run the object code and to modify the work, including scripts to
125 | control those activities. However, it does not include the work's
126 | System Libraries, or general-purpose tools or generally available free
127 | programs which are used unmodified in performing those activities but
128 | which are not part of the work. For example, Corresponding Source
129 | includes interface definition files associated with source files for
130 | the work, and the source code for shared libraries and dynamically
131 | linked subprograms that the work is specifically designed to require,
132 | such as by intimate data communication or control flow between those
133 | subprograms and other parts of the work.
134 |
135 | The Corresponding Source need not include anything that users
136 | can regenerate automatically from other parts of the Corresponding
137 | Source.
138 |
139 | The Corresponding Source for a work in source code form is that
140 | same work.
141 |
142 | 2. Basic Permissions.
143 |
144 | All rights granted under this License are granted for the term of
145 | copyright on the Program, and are irrevocable provided the stated
146 | conditions are met. This License explicitly affirms your unlimited
147 | permission to run the unmodified Program. The output from running a
148 | covered work is covered by this License only if the output, given its
149 | content, constitutes a covered work. This License acknowledges your
150 | rights of fair use or other equivalent, as provided by copyright law.
151 |
152 | You may make, run and propagate covered works that you do not
153 | convey, without conditions so long as your license otherwise remains
154 | in force. You may convey covered works to others for the sole purpose
155 | of having them make modifications exclusively for you, or provide you
156 | with facilities for running those works, provided that you comply with
157 | the terms of this License in conveying all material for which you do
158 | not control copyright. Those thus making or running the covered works
159 | for you must do so exclusively on your behalf, under your direction
160 | and control, on terms that prohibit them from making any copies of
161 | your copyrighted material outside their relationship with you.
162 |
163 | Conveying under any other circumstances is permitted solely under
164 | the conditions stated below. Sublicensing is not allowed; section 10
165 | makes it unnecessary.
166 |
167 | 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
168 |
169 | No covered work shall be deemed part of an effective technological
170 | measure under any applicable law fulfilling obligations under article
171 | 11 of the WIPO copyright treaty adopted on 20 December 1996, or
172 | similar laws prohibiting or restricting circumvention of such
173 | measures.
174 |
175 | When you convey a covered work, you waive any legal power to forbid
176 | circumvention of technological measures to the extent such circumvention
177 | is effected by exercising rights under this License with respect to
178 | the covered work, and you disclaim any intention to limit operation or
179 | modification of the work as a means of enforcing, against the work's
180 | users, your or third parties' legal rights to forbid circumvention of
181 | technological measures.
182 |
183 | 4. Conveying Verbatim Copies.
184 |
185 | You may convey verbatim copies of the Program's source code as you
186 | receive it, in any medium, provided that you conspicuously and
187 | appropriately publish on each copy an appropriate copyright notice;
188 | keep intact all notices stating that this License and any
189 | non-permissive terms added in accord with section 7 apply to the code;
190 | keep intact all notices of the absence of any warranty; and give all
191 | recipients a copy of this License along with the Program.
192 |
193 | You may charge any price or no price for each copy that you convey,
194 | and you may offer support or warranty protection for a fee.
195 |
196 | 5. Conveying Modified Source Versions.
197 |
198 | You may convey a work based on the Program, or the modifications to
199 | produce it from the Program, in the form of source code under the
200 | terms of section 4, provided that you also meet all of these conditions:
201 |
202 | a) The work must carry prominent notices stating that you modified
203 | it, and giving a relevant date.
204 |
205 | b) The work must carry prominent notices stating that it is
206 | released under this License and any conditions added under section
207 | 7. This requirement modifies the requirement in section 4 to
208 | "keep intact all notices".
209 |
210 | c) You must license the entire work, as a whole, under this
211 | License to anyone who comes into possession of a copy. This
212 | License will therefore apply, along with any applicable section 7
213 | additional terms, to the whole of the work, and all its parts,
214 | regardless of how they are packaged. This License gives no
215 | permission to license the work in any other way, but it does not
216 | invalidate such permission if you have separately received it.
217 |
218 | d) If the work has interactive user interfaces, each must display
219 | Appropriate Legal Notices; however, if the Program has interactive
220 | interfaces that do not display Appropriate Legal Notices, your
221 | work need not make them do so.
222 |
223 | A compilation of a covered work with other separate and independent
224 | works, which are not by their nature extensions of the covered work,
225 | and which are not combined with it such as to form a larger program,
226 | in or on a volume of a storage or distribution medium, is called an
227 | "aggregate" if the compilation and its resulting copyright are not
228 | used to limit the access or legal rights of the compilation's users
229 | beyond what the individual works permit. Inclusion of a covered work
230 | in an aggregate does not cause this License to apply to the other
231 | parts of the aggregate.
232 |
233 | 6. Conveying Non-Source Forms.
234 |
235 | You may convey a covered work in object code form under the terms
236 | of sections 4 and 5, provided that you also convey the
237 | machine-readable Corresponding Source under the terms of this License,
238 | in one of these ways:
239 |
240 | a) Convey the object code in, or embodied in, a physical product
241 | (including a physical distribution medium), accompanied by the
242 | Corresponding Source fixed on a durable physical medium
243 | customarily used for software interchange.
244 |
245 | b) Convey the object code in, or embodied in, a physical product
246 | (including a physical distribution medium), accompanied by a
247 | written offer, valid for at least three years and valid for as
248 | long as you offer spare parts or customer support for that product
249 | model, to give anyone who possesses the object code either (1) a
250 | copy of the Corresponding Source for all the software in the
251 | product that is covered by this License, on a durable physical
252 | medium customarily used for software interchange, for a price no
253 | more than your reasonable cost of physically performing this
254 | conveying of source, or (2) access to copy the
255 | Corresponding Source from a network server at no charge.
256 |
257 | c) Convey individual copies of the object code with a copy of the
258 | written offer to provide the Corresponding Source. This
259 | alternative is allowed only occasionally and noncommercially, and
260 | only if you received the object code with such an offer, in accord
261 | with subsection 6b.
262 |
263 | d) Convey the object code by offering access from a designated
264 | place (gratis or for a charge), and offer equivalent access to the
265 | Corresponding Source in the same way through the same place at no
266 | further charge. You need not require recipients to copy the
267 | Corresponding Source along with the object code. If the place to
268 | copy the object code is a network server, the Corresponding Source
269 | may be on a different server (operated by you or a third party)
270 | that supports equivalent copying facilities, provided you maintain
271 | clear directions next to the object code saying where to find the
272 | Corresponding Source. Regardless of what server hosts the
273 | Corresponding Source, you remain obligated to ensure that it is
274 | available for as long as needed to satisfy these requirements.
275 |
276 | e) Convey the object code using peer-to-peer transmission, provided
277 | you inform other peers where the object code and Corresponding
278 | Source of the work are being offered to the general public at no
279 | charge under subsection 6d.
280 |
281 | A separable portion of the object code, whose source code is excluded
282 | from the Corresponding Source as a System Library, need not be
283 | included in conveying the object code work.
284 |
285 | A "User Product" is either (1) a "consumer product", which means any
286 | tangible personal property which is normally used for personal, family,
287 | or household purposes, or (2) anything designed or sold for incorporation
288 | into a dwelling. In determining whether a product is a consumer product,
289 | doubtful cases shall be resolved in favor of coverage. For a particular
290 | product received by a particular user, "normally used" refers to a
291 | typical or common use of that class of product, regardless of the status
292 | of the particular user or of the way in which the particular user
293 | actually uses, or expects or is expected to use, the product. A product
294 | is a consumer product regardless of whether the product has substantial
295 | commercial, industrial or non-consumer uses, unless such uses represent
296 | the only significant mode of use of the product.
297 |
298 | "Installation Information" for a User Product means any methods,
299 | procedures, authorization keys, or other information required to install
300 | and execute modified versions of a covered work in that User Product from
301 | a modified version of its Corresponding Source. The information must
302 | suffice to ensure that the continued functioning of the modified object
303 | code is in no case prevented or interfered with solely because
304 | modification has been made.
305 |
306 | If you convey an object code work under this section in, or with, or
307 | specifically for use in, a User Product, and the conveying occurs as
308 | part of a transaction in which the right of possession and use of the
309 | User Product is transferred to the recipient in perpetuity or for a
310 | fixed term (regardless of how the transaction is characterized), the
311 | Corresponding Source conveyed under this section must be accompanied
312 | by the Installation Information. But this requirement does not apply
313 | if neither you nor any third party retains the ability to install
314 | modified object code on the User Product (for example, the work has
315 | been installed in ROM).
316 |
317 | The requirement to provide Installation Information does not include a
318 | requirement to continue to provide support service, warranty, or updates
319 | for a work that has been modified or installed by the recipient, or for
320 | the User Product in which it has been modified or installed. Access to a
321 | network may be denied when the modification itself materially and
322 | adversely affects the operation of the network or violates the rules and
323 | protocols for communication across the network.
324 |
325 | Corresponding Source conveyed, and Installation Information provided,
326 | in accord with this section must be in a format that is publicly
327 | documented (and with an implementation available to the public in
328 | source code form), and must require no special password or key for
329 | unpacking, reading or copying.
330 |
331 | 7. Additional Terms.
332 |
333 | "Additional permissions" are terms that supplement the terms of this
334 | License by making exceptions from one or more of its conditions.
335 | Additional permissions that are applicable to the entire Program shall
336 | be treated as though they were included in this License, to the extent
337 | that they are valid under applicable law. If additional permissions
338 | apply only to part of the Program, that part may be used separately
339 | under those permissions, but the entire Program remains governed by
340 | this License without regard to the additional permissions.
341 |
342 | When you convey a copy of a covered work, you may at your option
343 | remove any additional permissions from that copy, or from any part of
344 | it. (Additional permissions may be written to require their own
345 | removal in certain cases when you modify the work.) You may place
346 | additional permissions on material, added by you to a covered work,
347 | for which you have or can give appropriate copyright permission.
348 |
349 | Notwithstanding any other provision of this License, for material you
350 | add to a covered work, you may (if authorized by the copyright holders of
351 | that material) supplement the terms of this License with terms:
352 |
353 | a) Disclaiming warranty or limiting liability differently from the
354 | terms of sections 15 and 16 of this License; or
355 |
356 | b) Requiring preservation of specified reasonable legal notices or
357 | author attributions in that material or in the Appropriate Legal
358 | Notices displayed by works containing it; or
359 |
360 | c) Prohibiting misrepresentation of the origin of that material, or
361 | requiring that modified versions of such material be marked in
362 | reasonable ways as different from the original version; or
363 |
364 | d) Limiting the use for publicity purposes of names of licensors or
365 | authors of the material; or
366 |
367 | e) Declining to grant rights under trademark law for use of some
368 | trade names, trademarks, or service marks; or
369 |
370 | f) Requiring indemnification of licensors and authors of that
371 | material by anyone who conveys the material (or modified versions of
372 | it) with contractual assumptions of liability to the recipient, for
373 | any liability that these contractual assumptions directly impose on
374 | those licensors and authors.
375 |
376 | All other non-permissive additional terms are considered "further
377 | restrictions" within the meaning of section 10. If the Program as you
378 | received it, or any part of it, contains a notice stating that it is
379 | governed by this License along with a term that is a further
380 | restriction, you may remove that term. If a license document contains
381 | a further restriction but permits relicensing or conveying under this
382 | License, you may add to a covered work material governed by the terms
383 | of that license document, provided that the further restriction does
384 | not survive such relicensing or conveying.
385 |
386 | If you add terms to a covered work in accord with this section, you
387 | must place, in the relevant source files, a statement of the
388 | additional terms that apply to those files, or a notice indicating
389 | where to find the applicable terms.
390 |
391 | Additional terms, permissive or non-permissive, may be stated in the
392 | form of a separately written license, or stated as exceptions;
393 | the above requirements apply either way.
394 |
395 | 8. Termination.
396 |
397 | You may not propagate or modify a covered work except as expressly
398 | provided under this License. Any attempt otherwise to propagate or
399 | modify it is void, and will automatically terminate your rights under
400 | this License (including any patent licenses granted under the third
401 | paragraph of section 11).
402 |
403 | However, if you cease all violation of this License, then your
404 | license from a particular copyright holder is reinstated (a)
405 | provisionally, unless and until the copyright holder explicitly and
406 | finally terminates your license, and (b) permanently, if the copyright
407 | holder fails to notify you of the violation by some reasonable means
408 | prior to 60 days after the cessation.
409 |
410 | Moreover, your license from a particular copyright holder is
411 | reinstated permanently if the copyright holder notifies you of the
412 | violation by some reasonable means, this is the first time you have
413 | received notice of violation of this License (for any work) from that
414 | copyright holder, and you cure the violation prior to 30 days after
415 | your receipt of the notice.
416 |
417 | Termination of your rights under this section does not terminate the
418 | licenses of parties who have received copies or rights from you under
419 | this License. If your rights have been terminated and not permanently
420 | reinstated, you do not qualify to receive new licenses for the same
421 | material under section 10.
422 |
423 | 9. Acceptance Not Required for Having Copies.
424 |
425 | You are not required to accept this License in order to receive or
426 | run a copy of the Program. Ancillary propagation of a covered work
427 | occurring solely as a consequence of using peer-to-peer transmission
428 | to receive a copy likewise does not require acceptance. However,
429 | nothing other than this License grants you permission to propagate or
430 | modify any covered work. These actions infringe copyright if you do
431 | not accept this License. Therefore, by modifying or propagating a
432 | covered work, you indicate your acceptance of this License to do so.
433 |
434 | 10. Automatic Licensing of Downstream Recipients.
435 |
436 | Each time you convey a covered work, the recipient automatically
437 | receives a license from the original licensors, to run, modify and
438 | propagate that work, subject to this License. You are not responsible
439 | for enforcing compliance by third parties with this License.
440 |
441 | An "entity transaction" is a transaction transferring control of an
442 | organization, or substantially all assets of one, or subdividing an
443 | organization, or merging organizations. If propagation of a covered
444 | work results from an entity transaction, each party to that
445 | transaction who receives a copy of the work also receives whatever
446 | licenses to the work the party's predecessor in interest had or could
447 | give under the previous paragraph, plus a right to possession of the
448 | Corresponding Source of the work from the predecessor in interest, if
449 | the predecessor has it or can get it with reasonable efforts.
450 |
451 | You may not impose any further restrictions on the exercise of the
452 | rights granted or affirmed under this License. For example, you may
453 | not impose a license fee, royalty, or other charge for exercise of
454 | rights granted under this License, and you may not initiate litigation
455 | (including a cross-claim or counterclaim in a lawsuit) alleging that
456 | any patent claim is infringed by making, using, selling, offering for
457 | sale, or importing the Program or any portion of it.
458 |
459 | 11. Patents.
460 |
461 | A "contributor" is a copyright holder who authorizes use under this
462 | License of the Program or a work on which the Program is based. The
463 | work thus licensed is called the contributor's "contributor version".
464 |
465 | A contributor's "essential patent claims" are all patent claims
466 | owned or controlled by the contributor, whether already acquired or
467 | hereafter acquired, that would be infringed by some manner, permitted
468 | by this License, of making, using, or selling its contributor version,
469 | but do not include claims that would be infringed only as a
470 | consequence of further modification of the contributor version. For
471 | purposes of this definition, "control" includes the right to grant
472 | patent sublicenses in a manner consistent with the requirements of
473 | this License.
474 |
475 | Each contributor grants you a non-exclusive, worldwide, royalty-free
476 | patent license under the contributor's essential patent claims, to
477 | make, use, sell, offer for sale, import and otherwise run, modify and
478 | propagate the contents of its contributor version.
479 |
480 | In the following three paragraphs, a "patent license" is any express
481 | agreement or commitment, however denominated, not to enforce a patent
482 | (such as an express permission to practice a patent or covenant not to
483 | sue for patent infringement). To "grant" such a patent license to a
484 | party means to make such an agreement or commitment not to enforce a
485 | patent against the party.
486 |
487 | If you convey a covered work, knowingly relying on a patent license,
488 | and the Corresponding Source of the work is not available for anyone
489 | to copy, free of charge and under the terms of this License, through a
490 | publicly available network server or other readily accessible means,
491 | then you must either (1) cause the Corresponding Source to be so
492 | available, or (2) arrange to deprive yourself of the benefit of the
493 | patent license for this particular work, or (3) arrange, in a manner
494 | consistent with the requirements of this License, to extend the patent
495 | license to downstream recipients. "Knowingly relying" means you have
496 | actual knowledge that, but for the patent license, your conveying the
497 | covered work in a country, or your recipient's use of the covered work
498 | in a country, would infringe one or more identifiable patents in that
499 | country that you have reason to believe are valid.
500 |
501 | If, pursuant to or in connection with a single transaction or
502 | arrangement, you convey, or propagate by procuring conveyance of, a
503 | covered work, and grant a patent license to some of the parties
504 | receiving the covered work authorizing them to use, propagate, modify
505 | or convey a specific copy of the covered work, then the patent license
506 | you grant is automatically extended to all recipients of the covered
507 | work and works based on it.
508 |
509 | A patent license is "discriminatory" if it does not include within
510 | the scope of its coverage, prohibits the exercise of, or is
511 | conditioned on the non-exercise of one or more of the rights that are
512 | specifically granted under this License. You may not convey a covered
513 | work if you are a party to an arrangement with a third party that is
514 | in the business of distributing software, under which you make payment
515 | to the third party based on the extent of your activity of conveying
516 | the work, and under which the third party grants, to any of the
517 | parties who would receive the covered work from you, a discriminatory
518 | patent license (a) in connection with copies of the covered work
519 | conveyed by you (or copies made from those copies), or (b) primarily
520 | for and in connection with specific products or compilations that
521 | contain the covered work, unless you entered into that arrangement,
522 | or that patent license was granted, prior to 28 March 2007.
523 |
524 | Nothing in this License shall be construed as excluding or limiting
525 | any implied license or other defenses to infringement that may
526 | otherwise be available to you under applicable patent law.
527 |
528 | 12. No Surrender of Others' Freedom.
529 |
530 | If conditions are imposed on you (whether by court order, agreement or
531 | otherwise) that contradict the conditions of this License, they do not
532 | excuse you from the conditions of this License. If you cannot convey a
533 | covered work so as to satisfy simultaneously your obligations under this
534 | License and any other pertinent obligations, then as a consequence you may
535 | not convey it at all. For example, if you agree to terms that obligate you
536 | to collect a royalty for further conveying from those to whom you convey
537 | the Program, the only way you could satisfy both those terms and this
538 | License would be to refrain entirely from conveying the Program.
539 |
540 | 13. Remote Network Interaction; Use with the GNU General Public License.
541 |
542 | Notwithstanding any other provision of this License, if you modify the
543 | Program, your modified version must prominently offer all users
544 | interacting with it remotely through a computer network (if your version
545 | supports such interaction) an opportunity to receive the Corresponding
546 | Source of your version by providing access to the Corresponding Source
547 | from a network server at no charge, through some standard or customary
548 | means of facilitating copying of software. This Corresponding Source
549 | shall include the Corresponding Source for any work covered by version 3
550 | of the GNU General Public License that is incorporated pursuant to the
551 | following paragraph.
552 |
553 | Notwithstanding any other provision of this License, you have
554 | permission to link or combine any covered work with a work licensed
555 | under version 3 of the GNU General Public License into a single
556 | combined work, and to convey the resulting work. The terms of this
557 | License will continue to apply to the part which is the covered work,
558 | but the work with which it is combined will remain governed by version
559 | 3 of the GNU General Public License.
560 |
561 | 14. Revised Versions of this License.
562 |
563 | The Free Software Foundation may publish revised and/or new versions of
564 | the GNU Affero General Public License from time to time. Such new versions
565 | will be similar in spirit to the present version, but may differ in detail to
566 | address new problems or concerns.
567 |
568 | Each version is given a distinguishing version number. If the
569 | Program specifies that a certain numbered version of the GNU Affero General
570 | Public License "or any later version" applies to it, you have the
571 | option of following the terms and conditions either of that numbered
572 | version or of any later version published by the Free Software
573 | Foundation. If the Program does not specify a version number of the
574 | GNU Affero General Public License, you may choose any version ever published
575 | by the Free Software Foundation.
576 |
577 | If the Program specifies that a proxy can decide which future
578 | versions of the GNU Affero General Public License can be used, that proxy's
579 | public statement of acceptance of a version permanently authorizes you
580 | to choose that version for the Program.
581 |
582 | Later license versions may give you additional or different
583 | permissions. However, no additional obligations are imposed on any
584 | author or copyright holder as a result of your choosing to follow a
585 | later version.
586 |
587 | 15. Disclaimer of Warranty.
588 |
589 | THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
590 | APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
591 | HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
592 | OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
593 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
594 | PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
595 | IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
596 | ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
597 |
598 | 16. Limitation of Liability.
599 |
600 | IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
601 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
602 | THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
603 | GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
604 | USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
605 | DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
606 | PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
607 | EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
608 | SUCH DAMAGES.
609 |
610 | 17. Interpretation of Sections 15 and 16.
611 |
612 | If the disclaimer of warranty and limitation of liability provided
613 | above cannot be given local legal effect according to their terms,
614 | reviewing courts shall apply local law that most closely approximates
615 | an absolute waiver of all civil liability in connection with the
616 | Program, unless a warranty or assumption of liability accompanies a
617 | copy of the Program in return for a fee.
618 |
619 | END OF TERMS AND CONDITIONS
620 |
621 | How to Apply These Terms to Your New Programs
622 |
623 | If you develop a new program, and you want it to be of the greatest
624 | possible use to the public, the best way to achieve this is to make it
625 | free software which everyone can redistribute and change under these terms.
626 |
627 | To do so, attach the following notices to the program. It is safest
628 | to attach them to the start of each source file to most effectively
629 | state the exclusion of warranty; and each file should have at least
630 | the "copyright" line and a pointer to where the full notice is found.
631 |
632 |
633 | Copyright (C)
634 |
635 | This program is free software: you can redistribute it and/or modify
636 | it under the terms of the GNU Affero General Public License as published
637 | by the Free Software Foundation, either version 3 of the License, or
638 | (at your option) any later version.
639 |
640 | This program is distributed in the hope that it will be useful,
641 | but WITHOUT ANY WARRANTY; without even the implied warranty of
642 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
643 | GNU Affero General Public License for more details.
644 |
645 | You should have received a copy of the GNU Affero General Public License
646 | along with this program. If not, see .
647 |
648 | Also add information on how to contact you by electronic and paper mail.
649 |
650 | If your software can interact with users remotely through a computer
651 | network, you should also make sure that it provides a way for users to
652 | get its source. For example, if your program is a web application, its
653 | interface could display a "Source" link that leads users to an archive
654 | of the code. There are many ways you could offer source, and different
655 | solutions will be better for different programs; see section 13 for the
656 | specific requirements.
657 |
658 | You should also get your employer (if you work as a programmer) or school,
659 | if any, to sign a "copyright disclaimer" for the program, if necessary.
660 | For more information on this, and how to apply and follow the GNU AGPL, see
661 | .
662 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Elide
2 | **Elide** is a multi-protocol extensional API to provide support for some missing methods from the official Telegram Bot API like resolveUsername, getMessages etc.
3 |
4 | **Note**: `It's work-in-progess at the moment.`
5 |
6 | ## Installation
7 |
8 | - You can install it directly into your machine using go install command:
9 | ```go install github.com/anonyindian/elide```
10 | - **Manually Compiling** - You can also compile it manually without any extra steps using go build command:
11 | ```go build .```
12 |
13 | ## Usage
14 |
15 | Once you install elide, go through the following process to run it:
16 |
17 | 1. Run `elide init` command to generate the config file in the current directory.
18 | 2. Fill up the details in the generated config file correctly.
19 | 3. Run `elide run` in the current directory to start the server.
20 |
21 | Once you follow the above steps, your elide instance shall start successfully.
22 | You can reach me out on [telegram](https://t.me/CaptainPicard) in case you need any help regarding it, etc.
23 |
24 |
25 | ## Supported Methods
26 |
27 | ### > endpoint`/resolveUsername`
28 | This method can be used to resolve a telegram username.
29 |
30 | **Parameters**:
31 | - `username` (type string) (required): Username of the telegram channel/chat.
32 |
33 | ### > endpoint`/getMessages`
34 | This method can be used to get list of telegram messages in a chat.
35 |
36 | **Parameters**:
37 | - `chat_id` (type int64) (required): Unique identifier of the telegram channel/chat.
38 | - `message_ids` (type []int64) (required): List of ids of messages to be fetched.
39 |
40 | ### > endpoint`/deleteMessages`
41 | This method can be used to delete list of telegram messages in a chat.
42 |
43 | **Parameters**:
44 | - `chat_id` (type int64) (optional): Unique identifier of the telegram channel/chat.
45 | - `message_ids` (type []int64) (required): List of ids of messages to be fetched.
46 | - `revoke` (type bool) (optional): Pass `true` to revoke messages from a private chat.
47 |
48 | ### > endpoint`/getProfilePhotos`
49 | This method can be used to get list of profile photos in the form of telegra.ph link.
50 |
51 | **Parameters**:
52 | - `user_id` (type int64|string): Unique identifier of the telegram user.
53 | - `offset` (type int): If a positive value was transferred, the method will return only photos with IDs less than the set one.
54 | - `max_id` (type int64): Number of list elements to be returned
55 | - `limit` (type int): Number of list elements to be returned
56 |
57 | ### > endpoint`/getChatPhoto`
58 | This method can be used to get photo set in a chat in the form of telegra.ph link.
59 |
60 | **Parameters**:
61 | - `chat_id` (type int64|string): Unique identifier of the telegram chat.
62 |
63 | ## License
64 | Licensed under **GNU AFFERO GENERAL PUBLIC LICENSE V3**
65 |
--------------------------------------------------------------------------------
/cmd/cmd.go:
--------------------------------------------------------------------------------
1 | package cmd
2 |
3 | import (
4 | "fmt"
5 | "os"
6 | "strings"
7 | )
8 |
9 | const info = `Elide V1
10 | A multi-protocol extensional API to provide support for some missing methods from the official Telegram Bot API like resolveUsername, getMessages etc.`
11 |
12 | const help = `
13 | Commands:
14 | - help: shows this help section
15 | - init: creates a preset config in the current directory
16 | - run: starts the API server
17 | `
18 |
19 | func Execute() {
20 | args := os.Args[1:]
21 | if len(args) == 0 {
22 | // a hacky way to prevent more lines of codes
23 | args = []string{"help"}
24 | }
25 | switch arg := strings.ToLower(args[0]); arg {
26 | case "init":
27 | createConfig()
28 | fmt.Println(`Elide: Created a preset "elide.yaml", please edit it with your telegram auth keys!`)
29 | case "run":
30 | loadConfig()
31 | runServer()
32 | case "help":
33 | fmt.Printf("%s\n%s", info, help)
34 | default:
35 | fmt.Printf("'%s' is not a valid command!\n%s", arg, help)
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/cmd/conf.go:
--------------------------------------------------------------------------------
1 | package cmd
2 |
3 | import (
4 | "fmt"
5 | "log"
6 | "os"
7 |
8 | "github.com/spf13/viper"
9 | )
10 |
11 | const elideConfigFile = "elide.yaml"
12 |
13 | var (
14 | appId, protocol, port int
15 | apiHash, botToken string
16 | )
17 |
18 | func loadConfig() {
19 | defer log.Println("[Elide][Config]: Loaded config vars...")
20 | if err := viper.ReadInConfig(); err != nil {
21 | fmt.Println("Elide: failed to read config:", err.Error())
22 | os.Exit(1)
23 | }
24 | appId = viper.GetInt("app-id")
25 | protocol = viper.GetInt("protocol")
26 | port = viper.GetInt("port")
27 | apiHash = viper.GetString("api-hash")
28 | botToken = viper.GetString("bot-token")
29 | }
30 |
31 | func createConfig() {
32 | viper.Set("app-id", 0)
33 | viper.Set("api-hash", "")
34 | viper.Set("bot-token", "")
35 | viper.Set("protocol", 0)
36 | viper.Set("port", 9093)
37 | if err := viper.WriteConfig(); err != nil {
38 | fmt.Println("Elide: failed to write config:", err.Error())
39 | os.Exit(1)
40 | }
41 | }
42 |
43 | func init() {
44 | viper.SetConfigFile(elideConfigFile)
45 | }
46 |
--------------------------------------------------------------------------------
/cmd/flush.go:
--------------------------------------------------------------------------------
1 | package cmd
2 |
3 | import (
4 | "elide/internal/api/config"
5 | "log"
6 | "os"
7 | "time"
8 | )
9 |
10 | func runFlush() {
11 | defer log.Println("[Elide][Flush]: Started")
12 | for {
13 | // clean in every 3? days
14 | time.Sleep(time.Hour * 24 * 3)
15 | dir := config.WorkingDir + "/downloads/photos"
16 | _ = os.RemoveAll(dir)
17 | _ = os.MkdirAll(dir, os.ModeDir)
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/cmd/server.go:
--------------------------------------------------------------------------------
1 | package cmd
2 |
3 | import (
4 | "elide/internal/api"
5 | "elide/internal/api/config"
6 | "log"
7 | )
8 |
9 | func runServer() {
10 | defer log.Println("[Elide][MAIN]: Started")
11 | config.Debug = true
12 | engine := api.CreateEngine(protocol, port, appId, apiHash, botToken)
13 | go runFlush()
14 | engine.Run()
15 | }
16 |
--------------------------------------------------------------------------------
/go.mod:
--------------------------------------------------------------------------------
1 | module elide
2 |
3 | go 1.19
4 |
5 | require (
6 | github.com/anonyindian/gotgproto v1.0.0-beta09.0.20230314132427-0d3a18b6964c
7 | github.com/anonyindian/telegraph-go v1.2.2
8 | github.com/gotd/td v0.79.0
9 | github.com/spf13/viper v1.14.0
10 | go.uber.org/multierr v1.10.0
11 | )
12 |
13 | require (
14 | github.com/allegro/bigcache v1.2.1 // indirect
15 | github.com/cenkalti/backoff/v4 v4.2.0 // indirect
16 | github.com/fsnotify/fsnotify v1.6.0 // indirect
17 | github.com/go-faster/errors v0.6.1 // indirect
18 | github.com/go-faster/jx v1.0.0 // indirect
19 | github.com/go-faster/xor v1.0.0 // indirect
20 | github.com/gotd/ige v0.2.2 // indirect
21 | github.com/gotd/neo v0.1.5 // indirect
22 | github.com/hashicorp/hcl v1.0.0 // indirect
23 | github.com/jinzhu/inflection v1.0.0 // indirect
24 | github.com/jinzhu/now v1.1.5 // indirect
25 | github.com/klauspost/compress v1.16.3 // indirect
26 | github.com/magiconair/properties v1.8.6 // indirect
27 | github.com/mattn/go-sqlite3 v1.14.16 // indirect
28 | github.com/mitchellh/mapstructure v1.5.0 // indirect
29 | github.com/pelletier/go-toml v1.9.5 // indirect
30 | github.com/pelletier/go-toml/v2 v2.0.5 // indirect
31 | github.com/pkg/errors v0.9.1 // indirect
32 | github.com/segmentio/asm v1.2.0 // indirect
33 | github.com/spf13/afero v1.9.2 // indirect
34 | github.com/spf13/cast v1.5.0 // indirect
35 | github.com/spf13/jwalterweatherman v1.1.0 // indirect
36 | github.com/spf13/pflag v1.0.5 // indirect
37 | github.com/subosito/gotenv v1.4.1 // indirect
38 | go.opentelemetry.io/otel v1.14.0 // indirect
39 | go.opentelemetry.io/otel/trace v1.14.0 // indirect
40 | go.uber.org/atomic v1.10.0 // indirect
41 | go.uber.org/zap v1.24.0 // indirect
42 | golang.org/x/crypto v0.7.0 // indirect
43 | golang.org/x/net v0.8.0 // indirect
44 | golang.org/x/sync v0.1.0 // indirect
45 | golang.org/x/sys v0.6.0 // indirect
46 | golang.org/x/text v0.8.0 // indirect
47 | gopkg.in/ini.v1 v1.67.0 // indirect
48 | gopkg.in/yaml.v2 v2.4.0 // indirect
49 | gopkg.in/yaml.v3 v3.0.1 // indirect
50 | gorm.io/driver/sqlite v1.4.4 // indirect
51 | gorm.io/gorm v1.24.6 // indirect
52 | nhooyr.io/websocket v1.8.7 // indirect
53 | rsc.io/qr v0.2.0 // indirect
54 | )
55 |
--------------------------------------------------------------------------------
/go.sum:
--------------------------------------------------------------------------------
1 | cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
2 | cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
3 | cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU=
4 | cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU=
5 | cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY=
6 | cloud.google.com/go v0.44.3/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY=
7 | cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc=
8 | cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0=
9 | cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To=
10 | cloud.google.com/go v0.52.0/go.mod h1:pXajvRH/6o3+F9jDHZWQ5PbGhn+o8w9qiu/CffaVdO4=
11 | cloud.google.com/go v0.53.0/go.mod h1:fp/UouUEsRkN6ryDKNW/Upv/JBKnv6WDthjR6+vze6M=
12 | cloud.google.com/go v0.54.0/go.mod h1:1rq2OEkV3YMf6n/9ZvGWI3GWw0VoqH/1x2nd8Is/bPc=
13 | cloud.google.com/go v0.56.0/go.mod h1:jr7tqZxxKOVYizybht9+26Z/gUq7tiRzu+ACVAMbKVk=
14 | cloud.google.com/go v0.57.0/go.mod h1:oXiQ6Rzq3RAkkY7N6t3TcE6jE+CIBBbA36lwQ1JyzZs=
15 | cloud.google.com/go v0.62.0/go.mod h1:jmCYTdRCQuc1PHIIJ/maLInMho30T/Y0M4hTdTShOYc=
16 | cloud.google.com/go v0.65.0/go.mod h1:O5N8zS7uWy9vkA9vayVHs65eM1ubvY4h553ofrNHObY=
17 | cloud.google.com/go v0.72.0/go.mod h1:M+5Vjvlc2wnp6tjzE102Dw08nGShTscUx2nZMufOKPI=
18 | cloud.google.com/go v0.74.0/go.mod h1:VV1xSbzvo+9QJOxLDaJfTjx5e+MePCpCWwvftOeQmWk=
19 | cloud.google.com/go v0.75.0/go.mod h1:VGuuCn7PG0dwsd5XPVm2Mm3wlh3EL55/79EKB6hlPTY=
20 | cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o=
21 | cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE=
22 | cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc=
23 | cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUMb4Nv6dBIg=
24 | cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc=
25 | cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ=
26 | cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE=
27 | cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk=
28 | cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I=
29 | cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw=
30 | cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA=
31 | cloud.google.com/go/pubsub v1.3.1/go.mod h1:i+ucay31+CNRpDW4Lu78I4xXG+O1r/MAHgjpRVR+TSU=
32 | cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw=
33 | cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0ZeosJ0Rtdos=
34 | cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk=
35 | cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs=
36 | cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0=
37 | cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo=
38 | dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
39 | github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
40 | github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
41 | github.com/allegro/bigcache v1.2.1 h1:hg1sY1raCwic3Vnsvje6TT7/pnZba83LeFck5NrFKSc=
42 | github.com/allegro/bigcache v1.2.1/go.mod h1:Cb/ax3seSYIx7SuZdm2G2xzfwmv3TPSk2ucNfQESPXM=
43 | github.com/anonyindian/gotgproto v1.0.0-beta09.0.20230314132427-0d3a18b6964c h1:CA0A7jfBKTq2ougVE7EEN84vsZe88DX1R//JHbLDofI=
44 | github.com/anonyindian/gotgproto v1.0.0-beta09.0.20230314132427-0d3a18b6964c/go.mod h1:uMKJyWn+KYTwP9nZt+AjeiCiyPLpRkFpX4bgZB/Aowk=
45 | github.com/anonyindian/telegraph-go v1.2.2 h1:hmqoANR3lmv6xCcTAL9fY12lg6h160HzwF5cQW9B04s=
46 | github.com/anonyindian/telegraph-go v1.2.2/go.mod h1:q2VBz2iJUM8Yx+pl4B3VIkRXDV59YH0H4EBilM+/etA=
47 | github.com/benbjohnson/clock v1.1.0 h1:Q92kusRqC1XV2MjkWETPvjJVqKetz1OzxZB7mHJLju8=
48 | github.com/cenkalti/backoff/v4 v4.2.0 h1:HN5dHm3WBOgndBH6E8V0q2jIYIR3s9yglV8k/+MN3u4=
49 | github.com/cenkalti/backoff/v4 v4.2.0/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE=
50 | github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU=
51 | github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI=
52 | github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI=
53 | github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU=
54 | github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
55 | github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc=
56 | github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk=
57 | github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk=
58 | github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
59 | github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
60 | github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
61 | github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
62 | github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
63 | github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98=
64 | github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5ynNVH9qI8YYLbd1fK2po=
65 | github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk=
66 | github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
67 | github.com/frankban/quicktest v1.14.3 h1:FJKSZTDHjyhriyC81FLQ0LY93eSai0ZyR/ZIkd3ZUKE=
68 | github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY=
69 | github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw=
70 | github.com/gin-contrib/sse v0.1.0 h1:Y/yl/+YNO8GZSjAhjMsSuLt29uWRFHdHYUb5lYOV9qE=
71 | github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm+fLHvGI=
72 | github.com/gin-gonic/gin v1.6.3 h1:ahKqKTFpO5KTPHxWZjEdPScmYaGtLo8Y4DMHoEsnp14=
73 | github.com/gin-gonic/gin v1.6.3/go.mod h1:75u5sXoLsGZoRN5Sgbi1eraJ4GU3++wFwWzhwvtwp4M=
74 | github.com/go-faster/errors v0.6.1 h1:nNIPOBkprlKzkThvS/0YaX8Zs9KewLCOSFQS5BU06FI=
75 | github.com/go-faster/errors v0.6.1/go.mod h1:5MGV2/2T9yvlrbhe9pD9LO5Z/2zCSq2T8j+Jpi2LAyY=
76 | github.com/go-faster/jx v1.0.0 h1:HE+ms2e6ZGkZ6u13t8u+onBinrPvIPI+0hWXGELm74g=
77 | github.com/go-faster/jx v1.0.0/go.mod h1:zm8SlkwK+H0TYNKYtVJ/7cWFS7soJBQWhcPctKyYL/4=
78 | github.com/go-faster/xor v0.3.0/go.mod h1:x5CaDY9UKErKzqfRfFZdfu+OSTfoZny3w5Ak7UxcipQ=
79 | github.com/go-faster/xor v1.0.0 h1:2o8vTOgErSGHP3/7XwA5ib1FTtUsNtwCoLLBjl31X38=
80 | github.com/go-faster/xor v1.0.0/go.mod h1:x5CaDY9UKErKzqfRfFZdfu+OSTfoZny3w5Ak7UxcipQ=
81 | github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU=
82 | github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
83 | github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
84 | github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4=
85 | github.com/go-playground/locales v0.13.0 h1:HyWk6mgj5qFqCT5fjGBuRArbVDfE4hi8+e8ceBS/t7Q=
86 | github.com/go-playground/locales v0.13.0/go.mod h1:taPMhCMXrRLJO55olJkUXHZBHCxTMfnGwq/HNwmWNS8=
87 | github.com/go-playground/universal-translator v0.17.0 h1:icxd5fm+REJzpZx7ZfpaD876Lmtgy7VtROAbHHXk8no=
88 | github.com/go-playground/universal-translator v0.17.0/go.mod h1:UkSxE5sNxxRwHyU+Scu5vgOQjsIJAF8j9muTVoKLVtA=
89 | github.com/go-playground/validator/v10 v10.2.0 h1:KgJ0snyC2R9VXYN2rneOtQcw5aHQB1Vv0sFl1UcHBOY=
90 | github.com/go-playground/validator/v10 v10.2.0/go.mod h1:uOYAAleCW8F/7oMFd6aG0GOhaH6EGOAJShg8Id5JGkI=
91 | github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee h1:s+21KNqlpePfkah2I+gwHF8xmJWRjooY+5248k6m4A0=
92 | github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo=
93 | github.com/gobwas/pool v0.2.0 h1:QEmUOlnSjWtnpRGHF3SauEiOsy82Cup83Vf2LcMlnc8=
94 | github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw=
95 | github.com/gobwas/ws v1.0.2 h1:CoAavW/wd/kulfZmSIBt6p24n4j7tHgNVCjsfHVNUbo=
96 | github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM=
97 | github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
98 | github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
99 | github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
100 | github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
101 | github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
102 | github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
103 | github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y=
104 | github.com/golang/mock v1.4.0/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw=
105 | github.com/golang/mock v1.4.1/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw=
106 | github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw=
107 | github.com/golang/mock v1.4.4/go.mod h1:l3mdAwkq5BuhzHwde/uurv3sEJeZMXNpwsxVWU71h+4=
108 | github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
109 | github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
110 | github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
111 | github.com/golang/protobuf v1.3.3/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw=
112 | github.com/golang/protobuf v1.3.4/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw=
113 | github.com/golang/protobuf v1.3.5/go.mod h1:6O5/vntMXwX2lRkT1hjjk0nAC1IDOTvTlVgjlRvqsdk=
114 | github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8=
115 | github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA=
116 | github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs=
117 | github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w=
118 | github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0=
119 | github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8=
120 | github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI=
121 | github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI=
122 | github.com/golang/protobuf v1.5.2 h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw=
123 | github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
124 | github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
125 | github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M=
126 | github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
127 | github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
128 | github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
129 | github.com/google/go-cmp v0.4.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
130 | github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
131 | github.com/google/go-cmp v0.5.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
132 | github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
133 | github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
134 | github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38=
135 | github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
136 | github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs=
137 | github.com/google/martian/v3 v3.0.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0=
138 | github.com/google/martian/v3 v3.1.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0=
139 | github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc=
140 | github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc=
141 | github.com/google/pprof v0.0.0-20191218002539-d4f498aebedc/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
142 | github.com/google/pprof v0.0.0-20200212024743-f11f1df84d12/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
143 | github.com/google/pprof v0.0.0-20200229191704-1ebb73c60ed3/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
144 | github.com/google/pprof v0.0.0-20200430221834-fc25d7d30c6d/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
145 | github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
146 | github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
147 | github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
148 | github.com/google/pprof v0.0.0-20201218002935-b9804c9f04c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
149 | github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI=
150 | github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
151 | github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg=
152 | github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk=
153 | github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g=
154 | github.com/gorilla/websocket v1.4.1 h1:q7AeDBpnBk8AogcD4DSag/Ukw/KV+YhzLj2bP5HvKCM=
155 | github.com/gorilla/websocket v1.4.1/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE=
156 | github.com/gotd/ige v0.2.2 h1:XQ9dJZwBfDnOGSTxKXBGP4gMud3Qku2ekScRjDWWfEk=
157 | github.com/gotd/ige v0.2.2/go.mod h1:tuCRb+Y5Y3eNTo3ypIfNpQ4MFjrnONiL2jN2AKZXmb0=
158 | github.com/gotd/neo v0.1.5 h1:oj0iQfMbGClP8xI59x7fE/uHoTJD7NZH9oV1WNuPukQ=
159 | github.com/gotd/neo v0.1.5/go.mod h1:9A2a4bn9zL6FADufBdt7tZt+WMhvZoc5gWXihOPoiBQ=
160 | github.com/gotd/td v0.79.0 h1:nf2OTl9HvNlB8irzRnRVsIt4HZbuQbnnDM3VLnV002k=
161 | github.com/gotd/td v0.79.0/go.mod h1:ocM/yFZcTRQiUNnxtBc6gzUuUlFkXs6+GWSz8f1AZsc=
162 | github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
163 | github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
164 | github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4=
165 | github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
166 | github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
167 | github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
168 | github.com/jinzhu/inflection v1.0.0 h1:K317FqzuhWc8YvSVlFMCCUb36O/S9MCKRDI7QkRKD/E=
169 | github.com/jinzhu/inflection v1.0.0/go.mod h1:h+uFLlag+Qp1Va5pdKtLDYj+kHp5pxUVkryuEj+Srlc=
170 | github.com/jinzhu/now v1.1.4/go.mod h1:d3SSVoowX0Lcu0IBviAWJpolVfI5UJVZZ7cO71lE/z8=
171 | github.com/jinzhu/now v1.1.5 h1:/o9tlHleP7gOFmsnYNz3RGnqzefHA47wQpKrrdTIwXQ=
172 | github.com/jinzhu/now v1.1.5/go.mod h1:d3SSVoowX0Lcu0IBviAWJpolVfI5UJVZZ7cO71lE/z8=
173 | github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
174 | github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM=
175 | github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU=
176 | github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk=
177 | github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
178 | github.com/klauspost/compress v1.10.3/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs=
179 | github.com/klauspost/compress v1.16.3 h1:XuJt9zzcnaz6a16/OU53ZjWp/v7/42WcR5t2a0PcNQY=
180 | github.com/klauspost/compress v1.16.3/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE=
181 | github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg=
182 | github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
183 | github.com/kr/pretty v0.3.0 h1:WgNl7dwNpEZ6jJ9k1snq4pZsg7DOEN8hP9Xw0Tsjwk0=
184 | github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
185 | github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
186 | github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
187 | github.com/leodido/go-urn v1.2.0 h1:hpXL4XnriNwQ/ABnpepYM/1vCLWNDfUNts8dX3xTG6Y=
188 | github.com/leodido/go-urn v1.2.0/go.mod h1:+8+nEpDfqqsY+g338gtMEUOtuK+4dEMhiQEgxpxOKII=
189 | github.com/magiconair/properties v1.8.6 h1:5ibWZ6iY0NctNGWo87LalDlEZ6R41TqbbDamhfG/Qzo=
190 | github.com/magiconair/properties v1.8.6/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60=
191 | github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU=
192 | github.com/mattn/go-isatty v0.0.16 h1:bq3VjFmv/sOjHtdEhmkEV4x1AJtvUvOJ2PFAZ5+peKQ=
193 | github.com/mattn/go-sqlite3 v1.14.15/go.mod h1:2eHXhiwb8IkHr+BDWZGa96P6+rkvnG63S2DGjv9HUNg=
194 | github.com/mattn/go-sqlite3 v1.14.16 h1:yOQRA0RpS5PFz/oikGwBEqvAWhWg5ufRz4ETLjwpU1Y=
195 | github.com/mattn/go-sqlite3 v1.14.16/go.mod h1:2eHXhiwb8IkHr+BDWZGa96P6+rkvnG63S2DGjv9HUNg=
196 | github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY=
197 | github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
198 | github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
199 | github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg=
200 | github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
201 | github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M=
202 | github.com/pelletier/go-toml v1.9.5 h1:4yBQzkHv+7BHq2PQUZF3Mx0IYxG7LsP222s7Agd3ve8=
203 | github.com/pelletier/go-toml v1.9.5/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c=
204 | github.com/pelletier/go-toml/v2 v2.0.5 h1:ipoSadvV8oGUjnUbMub59IDPPwfxF694nG/jwbMiyQg=
205 | github.com/pelletier/go-toml/v2 v2.0.5/go.mod h1:OMHamSCAODeSsVrwwvcJOaoN0LIUIaFVNZzmWyNfXas=
206 | github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
207 | github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
208 | github.com/pkg/sftp v1.13.1/go.mod h1:3HaPG6Dq1ILlpPZRO0HVMrsydcdLt6HRDccSgb87qRg=
209 | github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
210 | github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
211 | github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
212 | github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
213 | github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8=
214 | github.com/segmentio/asm v1.2.0 h1:9BQrFxC+YOHJlTlHGkTrFWf59nbL3XnCoFLTwDCI7ys=
215 | github.com/segmentio/asm v1.2.0/go.mod h1:BqMnlJP91P8d+4ibuonYZw9mfnzI9HfxselHZr5aAcs=
216 | github.com/spf13/afero v1.9.2 h1:j49Hj62F0n+DaZ1dDCvhABaPNSGNkt32oRFxI33IEMw=
217 | github.com/spf13/afero v1.9.2/go.mod h1:iUV7ddyEEZPO5gA3zD4fJt6iStLlL+Lg4m2cihcDf8Y=
218 | github.com/spf13/cast v1.5.0 h1:rj3WzYc11XZaIZMPKmwP96zkFEnnAmV8s6XbB2aY32w=
219 | github.com/spf13/cast v1.5.0/go.mod h1:SpXXQ5YoyJw6s3/6cMTQuxvgRl3PCJiyaX9p6b155UU=
220 | github.com/spf13/jwalterweatherman v1.1.0 h1:ue6voC5bR5F8YxI5S67j9i582FU4Qvo2bmqnqMYADFk=
221 | github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo=
222 | github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA=
223 | github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
224 | github.com/spf13/viper v1.14.0 h1:Rg7d3Lo706X9tHsJMUjdiwMpHB7W8WnSVOssIY+JElU=
225 | github.com/spf13/viper v1.14.0/go.mod h1:WT//axPky3FdvXHzGw33dNdXXXfFQqmEalje+egj8As=
226 | github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
227 | github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw=
228 | github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
229 | github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
230 | github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
231 | github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA=
232 | github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
233 | github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
234 | github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
235 | github.com/stretchr/testify v1.8.2 h1:+h33VjcLVPDHtOdpUCuF+7gSuG3yGIftsP1YvFihtJ8=
236 | github.com/subosito/gotenv v1.4.1 h1:jyEFiXpy21Wm81FBN71l9VoMMV8H8jG+qIK3GCpY6Qs=
237 | github.com/subosito/gotenv v1.4.1/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0=
238 | github.com/ugorji/go v1.1.7 h1:/68gy2h+1mWMrwZFeD1kQialdSzAb432dtpeJ42ovdo=
239 | github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw=
240 | github.com/ugorji/go/codec v1.1.7 h1:2SvQaVZ1ouYrrKKwoSk2pzd4A9evlKJb9oTL+OaLUSs=
241 | github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY=
242 | github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
243 | github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
244 | github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
245 | github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
246 | go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
247 | go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
248 | go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
249 | go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
250 | go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
251 | go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk=
252 | go.opentelemetry.io/otel v1.14.0 h1:/79Huy8wbf5DnIPhemGB+zEPVwnN6fuQybr/SRXa6hM=
253 | go.opentelemetry.io/otel v1.14.0/go.mod h1:o4buv+dJzx8rohcUeRmWUZhqupFvzWis188WlggnNeU=
254 | go.opentelemetry.io/otel/trace v1.14.0 h1:wp2Mmvj41tDsyAJXiWDWpfNsOiIyd38fy85pyKcFq/M=
255 | go.opentelemetry.io/otel/trace v1.14.0/go.mod h1:8avnQLK+CG77yNLUae4ea2JDQ6iT+gozhnZjy/rw9G8=
256 | go.uber.org/atomic v1.10.0 h1:9qC72Qh0+3MqyJbAn8YU5xVq1frD8bn3JtD2oXtafVQ=
257 | go.uber.org/atomic v1.10.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0=
258 | go.uber.org/goleak v1.1.11 h1:wy28qYRKZgnJTxGxvye5/wgWr1EKjmUDGYox5mGlRlI=
259 | go.uber.org/multierr v1.10.0 h1:S0h4aNzvfcFsC3dRF1jLoaov7oRaKqRGC/pUEJ2yvPQ=
260 | go.uber.org/multierr v1.10.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y=
261 | go.uber.org/zap v1.24.0 h1:FiJd5l1UOLj0wCgbSE0rwwXHzEdAZS6hiiSnxJN/D60=
262 | go.uber.org/zap v1.24.0/go.mod h1:2kMP+WWQ8aoFoedH3T2sq6iJ2yDWpHbP0f6MQbS9Gkg=
263 | golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
264 | golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
265 | golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
266 | golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
267 | golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
268 | golang.org/x/crypto v0.0.0-20210421170649-83a5a9bb288b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4=
269 | golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
270 | golang.org/x/crypto v0.7.0 h1:AvwMYaRytfdeVt3u6mLaxYtErKYjxA2OXjJ1HHq6t3A=
271 | golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU=
272 | golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
273 | golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
274 | golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
275 | golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek=
276 | golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY=
277 | golang.org/x/exp v0.0.0-20191129062945-2f5052295587/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
278 | golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
279 | golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
280 | golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM=
281 | golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU=
282 | golang.org/x/exp v0.0.0-20230116083435-1de6713980de h1:DBWn//IJw30uYCgERoxCg84hWtA97F4wMiKOIh00Uf0=
283 | golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
284 | golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
285 | golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
286 | golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU=
287 | golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
288 | golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
289 | golang.org/x/lint v0.0.0-20190409202823-959b441ac422/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
290 | golang.org/x/lint v0.0.0-20190909230951-414d861bb4ac/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
291 | golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
292 | golang.org/x/lint v0.0.0-20191125180803-fdd1cda4f05f/go.mod h1:5qLYkcX4OjUUV8bRuDixDT3tpyyb+LUpUlRWLxfhWrs=
293 | golang.org/x/lint v0.0.0-20200130185559-910be7a94367/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
294 | golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
295 | golang.org/x/lint v0.0.0-20201208152925-83fdc39ff7b5/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
296 | golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE=
297 | golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o=
298 | golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc=
299 | golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY=
300 | golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
301 | golang.org/x/mod v0.1.1-0.20191107180719-034126e5016b/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
302 | golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
303 | golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
304 | golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
305 | golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
306 | golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
307 | golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
308 | golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
309 | golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
310 | golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
311 | golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
312 | golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
313 | golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
314 | golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks=
315 | golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
316 | golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
317 | golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
318 | golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
319 | golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
320 | golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
321 | golang.org/x/net v0.0.0-20200222125558-5a598a2470a0/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
322 | golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
323 | golang.org/x/net v0.0.0-20200301022130-244492dfa37a/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
324 | golang.org/x/net v0.0.0-20200324143707-d3edc9973b7e/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
325 | golang.org/x/net v0.0.0-20200501053045-e0ff5e5a1de5/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
326 | golang.org/x/net v0.0.0-20200506145744-7e3656a0809f/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
327 | golang.org/x/net v0.0.0-20200513185701-a91f0712d120/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
328 | golang.org/x/net v0.0.0-20200520182314-0ba52f642ac2/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
329 | golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA=
330 | golang.org/x/net v0.0.0-20200707034311-ab3426394381/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA=
331 | golang.org/x/net v0.0.0-20200822124328-c89045814202/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA=
332 | golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU=
333 | golang.org/x/net v0.0.0-20201031054903-ff519b6c9102/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU=
334 | golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
335 | golang.org/x/net v0.0.0-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
336 | golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
337 | golang.org/x/net v0.8.0 h1:Zrh2ngAOFYneWTAIAPethzeaQLuHwhuBkuV6ZiRnUaQ=
338 | golang.org/x/net v0.8.0/go.mod h1:QVkue5JL9kW//ek3r6jTKnTFis1tRmNAW2P1shuFdJc=
339 | golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
340 | golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
341 | golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
342 | golang.org/x/oauth2 v0.0.0-20191202225959-858c2ad4c8b6/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
343 | golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
344 | golang.org/x/oauth2 v0.0.0-20200902213428-5d25da1a8d43/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
345 | golang.org/x/oauth2 v0.0.0-20201109201403-9fd604954f58/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
346 | golang.org/x/oauth2 v0.0.0-20201208152858-08078c50e5b5/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
347 | golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
348 | golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
349 | golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
350 | golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
351 | golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
352 | golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
353 | golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
354 | golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
355 | golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
356 | golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
357 | golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
358 | golang.org/x/sync v0.1.0 h1:wsuoTGHzEhffawBOhz5CYhcrV4IdKZbEyZjBMuTp12o=
359 | golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
360 | golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
361 | golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
362 | golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
363 | golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
364 | golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
365 | golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
366 | golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
367 | golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
368 | golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
369 | golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
370 | golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
371 | golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
372 | golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
373 | golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
374 | golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
375 | golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
376 | golang.org/x/sys v0.0.0-20200212091648-12a6c2dcc1e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
377 | golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
378 | golang.org/x/sys v0.0.0-20200302150141-5c8b2ff67527/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
379 | golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
380 | golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
381 | golang.org/x/sys v0.0.0-20200501052902-10377860bb8e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
382 | golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
383 | golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
384 | golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
385 | golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
386 | golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
387 | golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
388 | golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
389 | golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
390 | golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
391 | golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
392 | golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
393 | golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
394 | golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
395 | golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
396 | golang.org/x/sys v0.6.0 h1:MVltZSvRTcU2ljQOhs94SXPftV6DCNnZViHeQps87pQ=
397 | golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
398 | golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
399 | golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
400 | golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
401 | golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
402 | golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
403 | golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
404 | golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
405 | golang.org/x/text v0.8.0 h1:57P1ETyNKtuIjB4SRd15iJxuhj8Gc416Y78H3qgMh68=
406 | golang.org/x/text v0.8.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8=
407 | golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
408 | golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
409 | golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
410 | golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
411 | golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
412 | golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY=
413 | golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
414 | golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
415 | golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
416 | golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
417 | golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
418 | golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
419 | golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
420 | golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
421 | golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
422 | golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
423 | golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
424 | golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
425 | golang.org/x/tools v0.0.0-20191113191852-77e3bb0ad9e7/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
426 | golang.org/x/tools v0.0.0-20191115202509-3a792d9c32b2/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
427 | golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
428 | golang.org/x/tools v0.0.0-20191125144606-a911d9008d1f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
429 | golang.org/x/tools v0.0.0-20191130070609-6e064ea0cf2d/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
430 | golang.org/x/tools v0.0.0-20191216173652-a0e659d51361/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
431 | golang.org/x/tools v0.0.0-20191227053925-7b8e75db28f4/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
432 | golang.org/x/tools v0.0.0-20200117161641-43d50277825c/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
433 | golang.org/x/tools v0.0.0-20200122220014-bf1340f18c4a/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
434 | golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
435 | golang.org/x/tools v0.0.0-20200204074204-1cc6d1ef6c74/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
436 | golang.org/x/tools v0.0.0-20200207183749-b753a1ba74fa/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
437 | golang.org/x/tools v0.0.0-20200212150539-ea181f53ac56/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
438 | golang.org/x/tools v0.0.0-20200224181240-023911ca70b2/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
439 | golang.org/x/tools v0.0.0-20200227222343-706bc42d1f0d/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
440 | golang.org/x/tools v0.0.0-20200304193943-95d2e580d8eb/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw=
441 | golang.org/x/tools v0.0.0-20200312045724-11d5b4c81c7d/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw=
442 | golang.org/x/tools v0.0.0-20200331025713-a30bf2db82d4/go.mod h1:Sl4aGygMT6LrqrWclx+PTx3U+LnKx/seiNR+3G19Ar8=
443 | golang.org/x/tools v0.0.0-20200501065659-ab2804fb9c9d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
444 | golang.org/x/tools v0.0.0-20200512131952-2bc93b1c0c88/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
445 | golang.org/x/tools v0.0.0-20200515010526-7d3b6ebf133d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
446 | golang.org/x/tools v0.0.0-20200618134242-20370b0cb4b2/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
447 | golang.org/x/tools v0.0.0-20200729194436-6467de6f59a7/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA=
448 | golang.org/x/tools v0.0.0-20200804011535-6c149bb5ef0d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA=
449 | golang.org/x/tools v0.0.0-20200825202427-b303f430e36d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA=
450 | golang.org/x/tools v0.0.0-20200904185747-39188db58858/go.mod h1:Cj7w3i3Rnn0Xh82ur9kSqwfTHTeVxaDqrfMjpcNT6bE=
451 | golang.org/x/tools v0.0.0-20201110124207-079ba7bd75cd/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
452 | golang.org/x/tools v0.0.0-20201201161351-ac6f37ff4c2a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
453 | golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
454 | golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
455 | golang.org/x/tools v0.0.0-20210108195828-e2f9c7f1fc8e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
456 | golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0=
457 | golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
458 | golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
459 | golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
460 | golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
461 | google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE=
462 | google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M=
463 | google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg=
464 | google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg=
465 | google.golang.org/api v0.13.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
466 | google.golang.org/api v0.14.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
467 | google.golang.org/api v0.15.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
468 | google.golang.org/api v0.17.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
469 | google.golang.org/api v0.18.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
470 | google.golang.org/api v0.19.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
471 | google.golang.org/api v0.20.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
472 | google.golang.org/api v0.22.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
473 | google.golang.org/api v0.24.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE=
474 | google.golang.org/api v0.28.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE=
475 | google.golang.org/api v0.29.0/go.mod h1:Lcubydp8VUV7KeIHD9z2Bys/sm/vGKnG1UHuDBSrHWM=
476 | google.golang.org/api v0.30.0/go.mod h1:QGmEvQ87FHZNiUVJkT14jQNYJ4ZJjdRF23ZXz5138Fc=
477 | google.golang.org/api v0.35.0/go.mod h1:/XrVsuzM0rZmrsbjJutiuftIzeuTQcEeaYcSk/mQ1dg=
478 | google.golang.org/api v0.36.0/go.mod h1:+z5ficQTmoYpPn8LCUNVpK5I7hwkpjbcgqA7I34qYtE=
479 | google.golang.org/api v0.40.0/go.mod h1:fYKFpnQN0DsDSKRVRcQSDQNtqWPfM9i+zNPxepjRCQ8=
480 | google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
481 | google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
482 | google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
483 | google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0=
484 | google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc=
485 | google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc=
486 | google.golang.org/appengine v1.6.7/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc=
487 | google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc=
488 | google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
489 | google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
490 | google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
491 | google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
492 | google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc=
493 | google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc=
494 | google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8=
495 | google.golang.org/genproto v0.0.0-20191108220845-16a3f7862a1a/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
496 | google.golang.org/genproto v0.0.0-20191115194625-c23dd37a84c9/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
497 | google.golang.org/genproto v0.0.0-20191216164720-4f79533eabd1/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
498 | google.golang.org/genproto v0.0.0-20191230161307-f3c370f40bfb/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
499 | google.golang.org/genproto v0.0.0-20200115191322-ca5a22157cba/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
500 | google.golang.org/genproto v0.0.0-20200122232147-0452cf42e150/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
501 | google.golang.org/genproto v0.0.0-20200204135345-fa8e72b47b90/go.mod h1:GmwEX6Z4W5gMy59cAlVYjN9JhxgbQH6Gn+gFDQe2lzA=
502 | google.golang.org/genproto v0.0.0-20200212174721-66ed5ce911ce/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
503 | google.golang.org/genproto v0.0.0-20200224152610-e50cd9704f63/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
504 | google.golang.org/genproto v0.0.0-20200228133532-8c2c7df3a383/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
505 | google.golang.org/genproto v0.0.0-20200305110556-506484158171/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
506 | google.golang.org/genproto v0.0.0-20200312145019-da6875a35672/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
507 | google.golang.org/genproto v0.0.0-20200331122359-1ee6d9798940/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
508 | google.golang.org/genproto v0.0.0-20200430143042-b979b6f78d84/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
509 | google.golang.org/genproto v0.0.0-20200511104702-f5ebc3bea380/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
510 | google.golang.org/genproto v0.0.0-20200515170657-fc4c6c6a6587/go.mod h1:YsZOwe1myG/8QRHRsmBRE1LrgQY60beZKjly0O1fX9U=
511 | google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo=
512 | google.golang.org/genproto v0.0.0-20200618031413-b414f8b61790/go.mod h1:jDfRM7FcilCzHH/e9qn6dsT145K34l5v+OpcnNgKAAA=
513 | google.golang.org/genproto v0.0.0-20200729003335-053ba62fc06f/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
514 | google.golang.org/genproto v0.0.0-20200804131852-c06518451d9c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
515 | google.golang.org/genproto v0.0.0-20200825200019-8632dd797987/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
516 | google.golang.org/genproto v0.0.0-20200904004341-0bd0a958aa1d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
517 | google.golang.org/genproto v0.0.0-20201109203340-2640f1f9cdfb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
518 | google.golang.org/genproto v0.0.0-20201201144952-b05cb90ed32e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
519 | google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
520 | google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
521 | google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
522 | google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
523 | google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
524 | google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
525 | google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=
526 | google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg=
527 | google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY=
528 | google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
529 | google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
530 | google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
531 | google.golang.org/grpc v1.28.0/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60=
532 | google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3IjizoKk=
533 | google.golang.org/grpc v1.30.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
534 | google.golang.org/grpc v1.31.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
535 | google.golang.org/grpc v1.31.1/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
536 | google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc=
537 | google.golang.org/grpc v1.34.0/go.mod h1:WotjhfgOW/POjDeRt8vscBtXq+2VjORFy659qA51WJ8=
538 | google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU=
539 | google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8=
540 | google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0=
541 | google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM=
542 | google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE=
543 | google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo=
544 | google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
545 | google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
546 | google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
547 | google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGjtUeSXeh4=
548 | google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c=
549 | google.golang.org/protobuf v1.28.1 h1:d0NfwRgPtno5B1Wa6L2DAG+KivqkdutMf1UhdNx175w=
550 | gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
551 | gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
552 | gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 h1:YR8cESwS4TdDjEe65xsg0ogRM/Nc3DYOhEAlW+xobZo=
553 | gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
554 | gopkg.in/ini.v1 v1.67.0 h1:Dgnx+6+nfE+IfzjUEISNeydPJh9AXNNsWbGP9KzCsOA=
555 | gopkg.in/ini.v1 v1.67.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
556 | gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
557 | gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
558 | gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY=
559 | gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ=
560 | gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
561 | gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
562 | gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
563 | gorm.io/driver/sqlite v1.4.4 h1:gIufGoR0dQzjkyqDyYSCvsYR6fba1Gw5YKDqKeChxFc=
564 | gorm.io/driver/sqlite v1.4.4/go.mod h1:0Aq3iPO+v9ZKbcdiz8gLWRw5VOPcBOPUQJFLq5e2ecI=
565 | gorm.io/gorm v1.24.0/go.mod h1:DVrVomtaYTbqs7gB/x2uVvqnXzv0nqjB396B8cG4dBA=
566 | gorm.io/gorm v1.24.6 h1:wy98aq9oFEetsc4CAbKD2SoBCdMzsbSIvSUUFJuHi5s=
567 | gorm.io/gorm v1.24.6/go.mod h1:L4uxeKpfBml98NYqVqwAdmV1a2nBtAec/cf3fpucW/k=
568 | honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
569 | honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
570 | honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
571 | honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
572 | honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg=
573 | honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
574 | honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
575 | nhooyr.io/websocket v1.8.7 h1:usjR2uOr/zjjkVMy0lW+PPohFok7PCow5sDjLgX4P4g=
576 | nhooyr.io/websocket v1.8.7/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0=
577 | rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
578 | rsc.io/qr v0.2.0 h1:6vBLea5/NRMVTz8V66gipeLycZMl/+UlFmk8DvqQ6WY=
579 | rsc.io/qr v0.2.0/go.mod h1:IF+uZjkb9fqyeF/4tlBoynqmQxUoPfWEKh921coOuXs=
580 | rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0=
581 | rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA=
582 |
--------------------------------------------------------------------------------
/internal/api/config/config.go:
--------------------------------------------------------------------------------
1 | package config
2 |
3 | import (
4 | "log"
5 | "os"
6 | )
7 |
8 | var Debug bool
9 |
10 | func Debugln(v ...any) {
11 | if !Debug {
12 | return
13 | }
14 | log.Println(v...)
15 | }
16 |
17 | func Debugf(format string, a ...any) {
18 | if !Debug {
19 | return
20 | }
21 | log.Printf(format, a...)
22 | }
23 |
24 | var WorkingDir, _ = os.Getwd()
25 |
--------------------------------------------------------------------------------
/internal/api/engine.go:
--------------------------------------------------------------------------------
1 | package api
2 |
3 | import (
4 | "context"
5 | "elide/internal/api/config"
6 | "elide/internal/api/methods"
7 | "elide/internal/api/server"
8 | "encoding/json"
9 | "errors"
10 | "log"
11 | "os"
12 | "time"
13 |
14 | "github.com/anonyindian/gotgproto"
15 | "github.com/anonyindian/gotgproto/dispatcher"
16 | "github.com/anonyindian/gotgproto/ext"
17 | "github.com/anonyindian/gotgproto/sessionMaker"
18 | "github.com/gotd/td/telegram"
19 | )
20 |
21 | const tgConnectionTimeout = 10
22 |
23 | type Engine struct {
24 | appId int
25 | apiHash string
26 | token string
27 | server *server.Server
28 | establishedConnection bool
29 | }
30 |
31 | func CreateEngine(protocol, port, appId int, apiHash, token string) *Engine {
32 | defer log.Println("[Elide][Engine]: Created a new instance...")
33 | return &Engine{
34 | appId: appId,
35 | apiHash: apiHash,
36 | token: token,
37 | server: server.New(protocol, port),
38 | }
39 | }
40 |
41 | func (e *Engine) establishTelegramConn() {
42 | gotgproto.StartClient(&gotgproto.ClientHelper{
43 | AppID: e.appId,
44 | ApiHash: e.apiHash,
45 | Session: sessionMaker.NewSession("elide-tg", sessionMaker.Session),
46 | BotToken: e.token,
47 | Dispatcher: dispatcher.MakeDispatcher(),
48 | TaskFunc: func(contx context.Context, client *telegram.Client) error {
49 | go func() {
50 | for {
51 | if gotgproto.Sender != nil {
52 | e.establishedConnection = true
53 | break
54 | }
55 | }
56 | config.Debugln("[Elide-DEBUG][Engine]: Established a connection to telegram...")
57 | e.server.Context = ext.NewContext(contx, gotgproto.Api, gotgproto.Self, gotgproto.Sender, nil)
58 | config.Debugln("[Elide-DEBUG][Engine][Server]: Populated server with pseudo context")
59 | }()
60 | return nil
61 | },
62 | })
63 | }
64 |
65 | func (e *Engine) Run() {
66 | log.Println("[Elide][Engine]: Establishing a connection to telegram...")
67 | go e.establishTelegramConn()
68 | i := 0
69 | for !e.establishedConnection {
70 | if i == tgConnectionTimeout {
71 | log.Println("[Elide][Engine]: Failed to establish connection to telegram: Timeout")
72 | os.Exit(1)
73 | }
74 | // Wait for telegram to connect
75 | time.Sleep(1 * time.Second)
76 | i++
77 | }
78 | log.Println("[Elide][Engine]: Loading method handlers...")
79 | e.loadHandlers()
80 | log.Println("[Elide][Engine]: Starting server...")
81 | e.server.Start()
82 | }
83 |
84 | func (e *Engine) loadHandlers() {
85 | e.server.AddHandler("echo", func(_ *ext.Context, body json.RawMessage) (any, error) {
86 | if body == nil {
87 | return nil, errors.New("no data provided")
88 | }
89 | return body, nil
90 | })
91 | e.server.AddHandler("resolveUsername", methods.ResolveUsername)
92 | e.server.AddHandler("deleteMessages", methods.DeleteMessages)
93 | e.server.AddHandler("getMessages", methods.GetMessages)
94 | e.server.AddHandler("getProfilePhotos", methods.GetProfilePhotos)
95 | e.server.AddHandler("getChatPhoto", methods.GetChatPhoto)
96 | }
97 |
--------------------------------------------------------------------------------
/internal/api/methods/deleteMessages.go:
--------------------------------------------------------------------------------
1 | package methods
2 |
3 | import (
4 | "elide/internal/helpers"
5 | "elide/pkg/elide"
6 | "encoding/json"
7 | "errors"
8 | "fmt"
9 |
10 | "github.com/anonyindian/gotgproto/ext"
11 | "github.com/anonyindian/gotgproto/storage"
12 | "github.com/gotd/td/tg"
13 | )
14 |
15 | func deleteMessages(ctx *ext.Context, chatId int64, messageIds []int, revoke bool) error {
16 | if chatId == 0 {
17 | _, err := ctx.Client.MessagesDeleteMessages(ctx.Context, &tg.MessagesDeleteMessagesRequest{
18 | ID: messageIds,
19 | Revoke: revoke,
20 | })
21 | return err
22 | }
23 | peer := storage.GetPeerById(chatId)
24 | if peer.ID == 0 {
25 | return ext.ErrPeerNotFound
26 | }
27 | _, err := ctx.Client.ChannelsDeleteMessages(ctx.Context, &tg.ChannelsDeleteMessagesRequest{
28 | Channel: &tg.InputChannel{
29 | ChannelID: peer.ID,
30 | AccessHash: peer.AccessHash,
31 | },
32 | ID: messageIds,
33 | })
34 | return err
35 | }
36 |
37 | func DeleteMessages(ctx *ext.Context, body json.RawMessage) (any, error) {
38 | var p elide.DeleteMessagesBody
39 | if err := json.Unmarshal(body, &p); err != nil {
40 | return nil, fmt.Errorf("failed to read body for deleteMessages: %s", err.Error())
41 | }
42 | if p.ChatId != 0 {
43 | p.ChatId = helpers.PatchChatIdFromBotApi(p.ChatId)
44 | }
45 | if p.MessageIds == nil || len(p.MessageIds) == 0 {
46 | return nil, errors.New("message ids not provided")
47 | }
48 | return nil, deleteMessages(ctx, p.ChatId, p.MessageIds, p.Revoke)
49 | }
50 |
--------------------------------------------------------------------------------
/internal/api/methods/getChatPhoto.go:
--------------------------------------------------------------------------------
1 | package methods
2 |
3 | import (
4 | photos "elide/internal/helpers/photos"
5 | telegraph "elide/internal/helpers/telegraph"
6 | "elide/pkg/elide"
7 | "encoding/json"
8 | "errors"
9 | "fmt"
10 |
11 | "github.com/anonyindian/gotgproto/ext"
12 | "github.com/anonyindian/gotgproto/generic"
13 | "github.com/gotd/td/tg"
14 | "go.uber.org/multierr"
15 | )
16 |
17 | func GetChatPhoto(ctx *ext.Context, body json.RawMessage) (any, error) {
18 | var p elide.GetChatPhotoBody
19 | if err := json.Unmarshal(body, &p); err != nil {
20 | return nil, fmt.Errorf("failed to read body for getChatPhoto: %s", err.Error())
21 | }
22 | if p.ChatId == nil {
23 | return nil, errors.New("chat_id not provided")
24 | }
25 | var (
26 | chat tg.ChatFullClass
27 | err error
28 | chatId int64
29 | )
30 | switch cid := p.ChatId.(type) {
31 | case int:
32 | chat, err = generic.GetChat(ctx, cid)
33 | case int64:
34 | chat, err = generic.GetChat(ctx, cid)
35 | case string:
36 | chat, err = generic.GetChat(ctx, cid)
37 | }
38 | if err != nil {
39 | return nil, err
40 | }
41 | var photo tg.PhotoClass
42 | switch v := chat.(type) {
43 | case *tg.ChannelFull:
44 | photo = v.ChatPhoto
45 | case *tg.ChatFull:
46 | photo = v.ChatPhoto
47 | }
48 | var errPhotoNotFound = errors.New("photo not found")
49 | if photo == nil {
50 | return nil, errPhotoNotFound
51 | }
52 | pPaths, photoErrs := photos.Download(ctx, chatId, []tg.PhotoClass{photo})
53 | if pPaths == nil {
54 | if photoErrs == nil {
55 | return nil, errPhotoNotFound
56 | }
57 | return nil, photoErrs
58 | }
59 | urls, tgraphErrs := telegraph.UploadFiles(pPaths)
60 | if urls != nil {
61 | return urls[0], photoErrs
62 | }
63 | return nil, multierr.Append(photoErrs, tgraphErrs)
64 | }
65 |
--------------------------------------------------------------------------------
/internal/api/methods/getMessages.go:
--------------------------------------------------------------------------------
1 | package methods
2 |
3 | import (
4 | "elide/internal/helpers"
5 | "elide/pkg/elide"
6 | "encoding/json"
7 | "errors"
8 | "fmt"
9 |
10 | "github.com/anonyindian/gotgproto/ext"
11 | "github.com/anonyindian/gotgproto/functions"
12 | "github.com/anonyindian/gotgproto/storage"
13 | "github.com/gotd/td/tg"
14 | )
15 |
16 | func getInputMessageIds(p *elide.GetMessagesBody) []tg.InputMessageClass {
17 | data := make([]tg.InputMessageClass, len(p.MessageIds))
18 | for i, v := range p.MessageIds {
19 | data[i] = &tg.InputMessageID{ID: v}
20 | }
21 | return data
22 | }
23 |
24 | func getMessages(ctx *ext.Context, chatId int64, messageIds []tg.InputMessageClass) ([]tg.MessageClass, error) {
25 | if chatId == 0 {
26 | return functions.GetChatMessages(ctx.Context, ctx.Client, messageIds)
27 | }
28 | peer := storage.GetPeerById(chatId)
29 | if peer.ID == 0 {
30 | return nil, ext.ErrPeerNotFound
31 | }
32 | switch storage.EntityType(peer.Type) {
33 | case storage.TypeChannel:
34 | return functions.GetChannelMessages(ctx.Context, ctx.Client, &tg.InputChannel{
35 | ChannelID: peer.ID,
36 | AccessHash: peer.AccessHash,
37 | }, messageIds)
38 | default:
39 | return functions.GetChatMessages(ctx.Context, ctx.Client, messageIds)
40 | }
41 | }
42 |
43 | func GetMessages(ctx *ext.Context, body json.RawMessage) (any, error) {
44 | var p elide.GetMessagesBody
45 | if err := json.Unmarshal(body, &p); err != nil {
46 | return nil, fmt.Errorf("failed to read body for getMessagesBody: %s", err.Error())
47 | }
48 | if p.ChatId != 0 {
49 | p.ChatId = helpers.PatchChatIdFromBotApi(p.ChatId)
50 | }
51 | if p.MessageIds == nil || len(p.MessageIds) == 0 {
52 | return nil, errors.New("message ids not provided")
53 | }
54 | return getMessages(ctx, p.ChatId, getInputMessageIds(&p))
55 | }
56 |
--------------------------------------------------------------------------------
/internal/api/methods/getProfilePhotos.go:
--------------------------------------------------------------------------------
1 | package methods
2 |
3 | import (
4 | "elide/pkg/elide"
5 | "encoding/json"
6 | "errors"
7 | "fmt"
8 |
9 | "elide/internal/helpers"
10 | photos "elide/internal/helpers/photos"
11 | telegraph "elide/internal/helpers/telegraph"
12 |
13 | "github.com/anonyindian/gotgproto/ext"
14 | "github.com/gotd/td/tg"
15 | "go.uber.org/multierr"
16 | )
17 |
18 | func GetProfilePhotos(ctx *ext.Context, body json.RawMessage) (any, error) {
19 | var p elide.GetProfilePhotosBody
20 | if err := json.Unmarshal(body, &p); err != nil {
21 | return nil, fmt.Errorf("failed to read body for getProfilePhotos: %s", err.Error())
22 | }
23 | if p.UserID == nil {
24 | return nil, errors.New("user_id not provided")
25 | }
26 | var (
27 | rawPhotos []tg.PhotoClass
28 | err error
29 | userId int64
30 | requestParams = &tg.PhotosGetUserPhotosRequest{
31 | Offset: p.Offset,
32 | MaxID: p.MaxID,
33 | Limit: p.Limit,
34 | }
35 | )
36 | switch uid := p.UserID.(type) {
37 | case int:
38 | rawPhotos, err = ctx.GetUserProfilePhotos(int64(uid), requestParams)
39 | if err != nil {
40 | return nil, err
41 | }
42 | userId = int64(uid)
43 | case int64:
44 | rawPhotos, err = ctx.GetUserProfilePhotos(uid, requestParams)
45 | if err != nil {
46 | return nil, err
47 | }
48 | userId = uid
49 | case string:
50 | peer, err := helpers.GetPeerByUsername(ctx, uid)
51 | if err != nil {
52 | return nil, err
53 | }
54 | requestParams.UserID = &tg.InputUser{
55 | UserID: peer.ID,
56 | AccessHash: peer.AccessHash,
57 | }
58 | rawRawPhotos, err := ctx.Client.PhotosGetUserPhotos(ctx, requestParams)
59 | if err != nil {
60 | return nil, err
61 | }
62 | rawPhotos = rawRawPhotos.GetPhotos()
63 | userId = peer.ID
64 | default:
65 | return nil, errors.New("unsupported type used for user_id")
66 | }
67 | pPaths, photoErrs := photos.Download(ctx, userId, rawPhotos)
68 | if pPaths == nil {
69 | if photoErrs == nil {
70 | return nil, errors.New("no photos found")
71 | }
72 | return nil, photoErrs
73 | }
74 | urls, tgraphErrs := telegraph.UploadFiles(pPaths)
75 | return urls, multierr.Append(photoErrs, tgraphErrs)
76 | }
77 |
--------------------------------------------------------------------------------
/internal/api/methods/resolveUsername.go:
--------------------------------------------------------------------------------
1 | package methods
2 |
3 | import (
4 | "elide/pkg/elide"
5 | "encoding/json"
6 | "errors"
7 | "fmt"
8 |
9 | "github.com/anonyindian/gotgproto/ext"
10 | )
11 |
12 | func ResolveUsername(ctx *ext.Context, body json.RawMessage) (any, error) {
13 | var p elide.ResolveUsernameBody
14 | if err := json.Unmarshal(body, &p); err != nil {
15 | return nil, fmt.Errorf("failed to read body for resolveUsername: %s", err.Error())
16 | }
17 | if p.Username == "" {
18 | return nil, errors.New("username not provided")
19 | }
20 | return ctx.ResolveUsername(p.Username)
21 | }
22 |
--------------------------------------------------------------------------------
/internal/api/request/request.go:
--------------------------------------------------------------------------------
1 | package request
2 |
3 | import "encoding/json"
4 |
5 | type Request struct {
6 | Method string `json:"method"`
7 | Data json.RawMessage `json:"data"`
8 | }
9 |
10 | func Parse(b []byte) (*Request, error) {
11 | var r Request
12 | if err := json.Unmarshal(b, &r); err != nil {
13 | return nil, err
14 | }
15 | return &r, nil
16 | }
17 |
--------------------------------------------------------------------------------
/internal/api/response/error.go:
--------------------------------------------------------------------------------
1 | package response
2 |
3 | import "encoding/json"
4 |
5 | func InitError(err error) []byte {
6 | if err == nil {
7 | return Error("Unknown")
8 | }
9 | return Error(err.Error())
10 | }
11 |
12 | func Error(err string) []byte {
13 | b, _ := json.Marshal(Response{
14 | Ok: false,
15 | Error: err,
16 | })
17 | return b
18 | }
19 |
--------------------------------------------------------------------------------
/internal/api/response/result.go:
--------------------------------------------------------------------------------
1 | package response
2 |
3 | import (
4 | "encoding/json"
5 | )
6 |
7 | type Response struct {
8 | Ok bool `json:"ok"`
9 | Error string `json:"error,omitempty"`
10 | Result any `json:"result,omitempty"`
11 | }
12 |
13 | func Result(res any) []byte {
14 | b, _ := json.Marshal(Response{
15 | Ok: true,
16 | Result: res,
17 | })
18 | return b
19 | }
20 |
--------------------------------------------------------------------------------
/internal/api/server/handler.go:
--------------------------------------------------------------------------------
1 | package server
2 |
3 | import (
4 | "encoding/json"
5 |
6 | "github.com/anonyindian/gotgproto/ext"
7 | )
8 |
9 | type HandlerFunc func(ctx *ext.Context, body json.RawMessage) (any, error)
10 |
--------------------------------------------------------------------------------
/internal/api/server/server.go:
--------------------------------------------------------------------------------
1 | package server
2 |
3 | import (
4 | "bufio"
5 | "elide/internal/api/request"
6 | "elide/internal/api/response"
7 | "encoding/json"
8 | "fmt"
9 | "io"
10 | "net"
11 | "net/http"
12 | "net/url"
13 | "os"
14 | "strconv"
15 | "strings"
16 |
17 | "github.com/anonyindian/gotgproto/ext"
18 | )
19 |
20 | type Server struct {
21 | protocol int
22 | port int
23 | handler map[string]HandlerFunc
24 | Context *ext.Context
25 | }
26 |
27 | func New(protocol, port int) *Server {
28 | return &Server{
29 | protocol: protocol,
30 | port: port,
31 | handler: make(map[string]HandlerFunc),
32 | }
33 | }
34 |
35 | func (s *Server) AddHandler(method string, handler HandlerFunc) {
36 | s.handler[method] = handler
37 | }
38 |
39 | func (s *Server) handlerWrapper(w io.Writer, b []byte) bool {
40 | req, err := request.Parse(b)
41 | if err != nil {
42 | w.Write(response.InitError(err))
43 | return false
44 | }
45 | rHandler, ok := s.handler[req.Method]
46 | if !ok {
47 | w.Write(response.Error("unknown method: " + req.Method))
48 | return false
49 | }
50 | res, err := rHandler(s.Context, req.Data)
51 | if err != nil {
52 | w.Write(response.InitError(err))
53 | return false
54 | }
55 | w.Write(response.Result(res))
56 | return true
57 | }
58 |
59 | func parseFormData(url *url.URL) map[string]any {
60 | sRaw := strings.Split(url.RawQuery, "&")
61 | paramKeys := make([]string, len(sRaw))
62 | for i, s := range sRaw {
63 | paramKeys[i] = strings.Split(s, "=")[0]
64 | }
65 | v := url.Query()
66 | params := make(map[string]any)
67 | for _, key := range paramKeys {
68 | val := v.Get(key)
69 | nVal, err := strconv.ParseInt(val, 10, 64)
70 | if err == nil {
71 | params[key] = nVal
72 | continue
73 | }
74 | bVal, err := strconv.ParseBool(val)
75 | if err == nil {
76 | params[key] = bVal
77 | continue
78 | }
79 | if val[0] == '[' && val[len(val)-1] == ']' {
80 | if len(val) == 2 {
81 | continue
82 | }
83 | arrElems := strings.Split(val[1:(len(val)-1)], ",")
84 | var arr = make([]any, len(arrElems))
85 | for i, arrValue := range arrElems {
86 | arrValue = strings.TrimSpace(arrValue)
87 | nArrValue, err := strconv.ParseInt(arrValue, 10, 64)
88 | if err == nil {
89 | arr[i] = nArrValue
90 | } else {
91 | arr[i] = arrValue
92 | }
93 | }
94 | params[key] = arr
95 | continue
96 | }
97 | params[key] = val
98 | }
99 | return params
100 | }
101 |
102 | func (s *Server) send(conn net.Conn, buf []byte) {
103 | conn.Write(buf)
104 | s.transmitEnd(conn)
105 | }
106 |
107 | func (s *Server) transmitEnd(conn net.Conn) {
108 | conn.Write([]byte{0})
109 | }
110 |
111 | func (s *Server) Start() {
112 | // go e.establishTelegramConn()
113 | addr := fmt.Sprintf("0.0.0.0:%d", s.port)
114 | switch s.protocol {
115 | case 0:
116 | // HTTP
117 | mux := http.NewServeMux()
118 | mux.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
119 | if r.URL.Path != "/" {
120 | method := r.URL.Path[1:]
121 | rHandler, ok := s.handler[method]
122 | if ok {
123 | params := parseFormData(r.URL)
124 | data, err := json.Marshal(params)
125 | if err != nil {
126 | w.Write(response.InitError(err))
127 | return
128 | }
129 | res, err := rHandler(s.Context, data)
130 | if err != nil {
131 | w.Write(response.InitError(err))
132 | return
133 | }
134 | w.Write(response.Result(res))
135 | return
136 | }
137 | }
138 | body := r.Body
139 | b, err := io.ReadAll(body)
140 | if err != nil {
141 | w.Write(response.InitError(err))
142 | return
143 | }
144 | if len(b) == 0 {
145 | method, data := r.FormValue("method"), r.FormValue("data")
146 | if method == "" || data == "" {
147 | w.Write(response.Error("insufficient info provided"))
148 | return
149 | }
150 | b = []byte(fmt.Sprintf(`{"method":"%s","data":%s}`, method, data))
151 | }
152 | _ = s.handlerWrapper(w, b)
153 | })
154 | server := http.Server{
155 | Addr: addr,
156 | Handler: mux,
157 | }
158 | if err := server.ListenAndServe(); err != nil {
159 | panic(err.Error())
160 | }
161 | case 1:
162 | // TCP
163 | l, err := net.Listen("tcp", addr)
164 | if err != nil {
165 | fmt.Println("failed to listen on", "tcp", ":", err.Error())
166 | os.Exit(1)
167 | }
168 | defer l.Close()
169 | for {
170 | conn, err := l.Accept()
171 | if err != nil {
172 | fmt.Println("Error accepting: ", err.Error())
173 | os.Exit(1)
174 | }
175 | // Handle connections in a new goroutine.
176 | go func(conn net.Conn) {
177 | for {
178 | b, err := bufio.NewReader(conn).ReadBytes(0)
179 | if err != nil {
180 | s.send(conn, response.InitError(err))
181 | return
182 | }
183 | _ = s.handlerWrapper(conn, b[:len(b)-1])
184 | s.transmitEnd(conn)
185 | }
186 | // err = conn.Close()
187 | // if err != nil {
188 | // fmt.Println("failed to close connection:", err.Error())
189 | // }
190 | }(conn)
191 | }
192 | case 2:
193 | fmt.Println("UDP is not implemented yet, please use HTTP or TCP instead!")
194 | os.Exit(1)
195 | }
196 | }
197 |
--------------------------------------------------------------------------------
/internal/api/types/chat.go:
--------------------------------------------------------------------------------
1 | package types
2 |
--------------------------------------------------------------------------------
/internal/helpers/helpers.go:
--------------------------------------------------------------------------------
1 | package helpers
2 |
3 | import (
4 | "fmt"
5 | "strconv"
6 | "strings"
7 |
8 | "github.com/anonyindian/gotgproto/ext"
9 | "github.com/anonyindian/gotgproto/storage"
10 | )
11 |
12 | type Peer struct {
13 | ID int64
14 | AccessHash int64
15 | }
16 |
17 | func GetPeerByUsername(ctx *ext.Context, username string) (*Peer, error) {
18 | peer := storage.GetPeerByUsername(username)
19 | if peer.ID != 0 {
20 | return &Peer{peer.ID, peer.AccessHash}, nil
21 | }
22 | chat, err := ctx.ResolveUsername(username)
23 | if err != nil {
24 | return nil, err
25 | }
26 | return &Peer{chat.GetID(), chat.GetAccessHash()}, nil
27 | }
28 |
29 | func PatchChatIdFromBotApi(chatId int64) int64 {
30 | chat := strings.TrimPrefix(fmt.Sprint(chatId), "-100")
31 | chatId, _ = strconv.ParseInt(chat, 10, 64)
32 | return chatId
33 | }
34 |
35 | func PatchChatIdToBotApi(chatId int64) int64 {
36 | if chat := fmt.Sprint(chatId); !strings.HasPrefix(chat, "-100") {
37 | chat = "-100" + chat
38 | chatId, _ = strconv.ParseInt(chat, 10, 64)
39 | }
40 | return chatId
41 | }
42 |
--------------------------------------------------------------------------------
/internal/helpers/photos/photos.go:
--------------------------------------------------------------------------------
1 | package helpers
2 |
3 | import (
4 | "elide/internal/api/config"
5 | "fmt"
6 | "os"
7 | "strconv"
8 |
9 | "github.com/anonyindian/gotgproto/ext"
10 | "github.com/gotd/td/telegram/downloader"
11 | "github.com/gotd/td/tg"
12 | "go.uber.org/multierr"
13 | )
14 |
15 | func Download(ctx *ext.Context, userId int64, p []tg.PhotoClass) ([]string, error) {
16 | d := downloader.NewDownloader()
17 | var err error
18 | var pPaths []string
19 | for _, pc := range p {
20 | photo, ok := pc.AsNotEmpty()
21 | if !ok {
22 | continue
23 | }
24 | var loc tg.InputFileLocationClass
25 | if photo.VideoSizes != nil {
26 | tType := ""
27 | for _, vsz := range photo.VideoSizes {
28 | vs, ok := vsz.(*tg.VideoSize)
29 | if !ok {
30 | continue
31 | }
32 | tType = vs.Type
33 | }
34 | loc = &tg.InputPhotoFileLocation{
35 | ID: photo.ID,
36 | AccessHash: photo.AccessHash,
37 | FileReference: photo.FileReference,
38 | ThumbSize: tType,
39 | }
40 | } else {
41 | loc = &tg.InputPhotoFileLocation{
42 | ID: photo.ID,
43 | AccessHash: photo.AccessHash,
44 | FileReference: photo.FileReference,
45 | ThumbSize: photo.Sizes[len(photo.Sizes)-1].GetType(),
46 | }
47 | }
48 | userDir := fmt.Sprintf("%s/downloads/photos/%s", config.WorkingDir, strconv.FormatInt(userId, 10))
49 | pPath := fmt.Sprintf("%s/%d_%d", userDir, photo.ID, photo.AccessHash)
50 |
51 | if _, err111 := os.Stat(pPath); os.IsNotExist(err111) {
52 | config.Debugf("[Elide-DEBUG][Photos][Downloader]: file %d-%d not found in cache\n", photo.ID, photo.AccessHash)
53 | err1 := downloadFile(ctx, d, loc, userDir, pPath)
54 | if err != nil {
55 | err = multierr.Append(err, err1)
56 | continue
57 | }
58 | } else {
59 | config.Debugf("[Elide-DEBUG][Photos][Downloader]: file %d-%d found in cache\n", photo.ID, photo.AccessHash)
60 | }
61 | pPaths = append(pPaths, pPath)
62 | }
63 | return pPaths, err
64 | }
65 |
66 | func downloadFile(ctx *ext.Context, d *downloader.Downloader, loc tg.InputFileLocationClass, userDir, pPath string) error {
67 | db := d.Download(ctx.Client, loc)
68 | _, fErr := os.Stat(userDir)
69 | if fErr != nil {
70 | os.Mkdir(userDir, os.ModeDir)
71 | }
72 | _, err1 := db.ToPath(ctx, pPath)
73 | return err1
74 | }
75 |
--------------------------------------------------------------------------------
/internal/helpers/telegraph/init.go:
--------------------------------------------------------------------------------
1 | package telegraph
2 |
3 | import (
4 | "strings"
5 |
6 | telegraphPkg "github.com/anonyindian/telegraph-go"
7 | "go.uber.org/multierr"
8 | )
9 |
10 | func UploadFiles(pPaths []string) ([]string, error) {
11 | var uploaded = []string{}
12 | var err error
13 | for _, pPath := range pPaths {
14 | url, err1 := telegraphPkg.UploadFile(pPath)
15 | if err != nil {
16 | err = multierr.Append(err, err1)
17 | continue
18 | }
19 | uploaded = append(uploaded, strings.Join([]string{"telegra.ph", url}, ""))
20 | }
21 | return uploaded, err
22 | }
23 |
--------------------------------------------------------------------------------
/main.go:
--------------------------------------------------------------------------------
1 | package main
2 |
3 | import (
4 | "elide/cmd"
5 | "fmt"
6 | "os"
7 | )
8 |
9 | func main() {
10 | fmt.Println(os.MkdirAll("downloads/photos", os.ModeDir))
11 | cmd.Execute()
12 | }
13 |
--------------------------------------------------------------------------------
/pkg/elide/conn.go:
--------------------------------------------------------------------------------
1 | package elide
2 |
3 | import (
4 | "bufio"
5 | "bytes"
6 | "io"
7 | "net/http"
8 | )
9 |
10 | func (c *Client) MakeRequest(buf []byte) ([]byte, error) {
11 | switch c.Protocol {
12 | case 1:
13 | return c.makeTCPRequest(buf)
14 | default:
15 | return c.makeHTTPRequest(buf)
16 | }
17 | }
18 |
19 | func (c *Client) makeHTTPRequest(buf []byte) ([]byte, error) {
20 | r, err := http.NewRequest(http.MethodPost, c.addr, bytes.NewBuffer(buf))
21 | if err != nil {
22 | return nil, err
23 | }
24 | buf, err = io.ReadAll(r.Body)
25 | if err != nil {
26 | return nil, err
27 | }
28 | return buf, r.Body.Close()
29 | }
30 |
31 | func (c *Client) makeTCPRequest(buf []byte) ([]byte, error) {
32 | _, err := c.conn.Write(append(buf, 0))
33 | if err != nil {
34 | return nil, err
35 | }
36 | buf, err = bufio.NewReader(c.conn).ReadBytes(0)
37 | if err != nil {
38 | return nil, err
39 | }
40 | return buf[:len(buf)-1], nil
41 | }
42 |
--------------------------------------------------------------------------------
/pkg/elide/errors.go:
--------------------------------------------------------------------------------
1 | package elide
2 |
3 | type TelegramError struct {
4 | rpc string
5 | }
6 |
7 | func (t *TelegramError) Error() string {
8 | return t.rpc
9 | }
10 |
--------------------------------------------------------------------------------
/pkg/elide/methods.go:
--------------------------------------------------------------------------------
1 | package elide
2 |
3 | import (
4 | "elide/internal/helpers"
5 | "encoding/json"
6 | )
7 |
8 | func (c *Client) ResolveUsername(username string) (*Chat, error) {
9 | buf, err := json.Marshal(Body{
10 | Method: "resolveUsername",
11 | Data: ResolveUsernameBody{
12 | Username: username,
13 | },
14 | })
15 | if err != nil {
16 | return nil, err
17 | }
18 | buf, err = c.MakeRequest(buf)
19 | if err != nil {
20 | return nil, err
21 | }
22 | var res Response[*Chat]
23 | err = json.Unmarshal(buf, &res)
24 | if err != nil {
25 | return nil, err
26 | }
27 | if res.Ok {
28 | (&res).Result.ID = helpers.PatchChatIdToBotApi(res.Result.ID)
29 | } else {
30 | return nil, &TelegramError{rpc: res.Error}
31 | }
32 | return res.Result, nil
33 | }
34 |
35 | func (c *Client) GetMessages(chatId int64, messages []int) (*Message, error) {
36 | buf, err := json.Marshal(Body{
37 | Method: "getMessages",
38 | Data: GetMessagesBody{
39 | ChatId: chatId,
40 | MessageIds: messages,
41 | },
42 | })
43 | if err != nil {
44 | return nil, err
45 | }
46 | buf, err = c.MakeRequest(buf)
47 | if err != nil {
48 | return nil, err
49 | }
50 | var res Response[*Message]
51 | err = json.Unmarshal(buf, &res)
52 | if err != nil {
53 | return nil, err
54 | }
55 | if !res.Ok {
56 | return nil, &TelegramError{rpc: res.Error}
57 | }
58 | return res.Result, nil
59 | }
60 |
--------------------------------------------------------------------------------
/pkg/elide/types.go:
--------------------------------------------------------------------------------
1 | package elide
2 |
3 | import (
4 | "encoding/json"
5 | "fmt"
6 | "net"
7 |
8 | "github.com/gotd/td/tg"
9 | )
10 |
11 | type Client struct {
12 | Port, Protocol int
13 | conn net.Conn
14 | addr string
15 | }
16 |
17 | type Response[T comparable] struct {
18 | Ok bool `json:"ok"`
19 | Error string `json:"error,omitempty"`
20 | Result T `json:"result,omitempty"`
21 | }
22 |
23 | func NewClient(protocol, port int) (*Client, error) {
24 | c := &Client{
25 | Protocol: protocol,
26 | Port: port,
27 | }
28 | switch protocol {
29 | case 0:
30 | c.addr = fmt.Sprintf("http://0.0.0.0:%d", port)
31 | case 1:
32 | c.addr = fmt.Sprintf("0.0.0.0:%d", port)
33 | conn, err := net.Dial("tcp", c.addr)
34 | if err != nil {
35 | return nil, err
36 | }
37 | c.conn = conn
38 | }
39 | return c, nil
40 | }
41 |
42 | type Body struct {
43 | Method string `json:"method"`
44 | Data any `json:"data"`
45 | }
46 |
47 | type DeleteMessagesBody struct {
48 | ChatId int64 `json:"chat_id,omitempty"`
49 | MessageIds []int `json:"message_ids"`
50 | Revoke bool `json:"revoke,omitempty"`
51 | }
52 |
53 | type GetMessagesBody struct {
54 | ChatId int64 `json:"chat_id"`
55 | MessageIds []int `json:"message_ids"`
56 | }
57 |
58 | type ResolveUsernameBody struct {
59 | Username string `json:"username"`
60 | }
61 |
62 | type GetChatPhotoBody struct {
63 | // User ID
64 | ChatId any `json:"chat_id"`
65 | }
66 |
67 | type GetProfilePhotosBody struct {
68 | // User ID
69 | UserID any `json:"user_id"`
70 | // Number of list elements to be skipped
71 | Offset int `json:"offset,omitempty"`
72 | // If a positive value was transferred, the method will return only photos with IDs less
73 | // than the set one
74 | MaxID int64 `json:"max_id,omitempty"`
75 | // Number of list elements to be returned
76 | Limit int `json:"limit,omitempty"`
77 | }
78 |
79 | // Message represents TL type `message#38116ee0`.
80 | // A message
81 | //
82 | // See https://core.telegram.org/constructor/message for reference.
83 | type Message struct {
84 | // Is this an outgoing message
85 | Out bool
86 | // Whether we were mentioned¹ in this message
87 | //
88 | // Links:
89 | // 1) https://core.telegram.org/api/mentions
90 | Mentioned bool
91 | // Whether there are unread media attachments in this message
92 | MediaUnread bool
93 | // Whether this is a silent message (no notification triggered)
94 | Silent bool
95 | // Whether this is a channel post
96 | Post bool
97 | // Whether this is a scheduled message¹
98 | //
99 | // Links:
100 | // 1) https://core.telegram.org/api/scheduled-messages
101 | FromScheduled bool
102 | // This is a legacy message: it has to be refetched with the new layer
103 | Legacy bool
104 | // Whether the message should be shown as not modified to the user, even if an edit date
105 | // is present
106 | EditHide bool
107 | // Whether this message is pinned¹
108 | //
109 | // Links:
110 | // 1) https://core.telegram.org/api/pin
111 | Pinned bool
112 | // Whether this message is protected¹ and thus cannot be forwarded
113 | //
114 | // Links:
115 | // 1) https://telegram.org/blog/protected-content-delete-by-date-and-more
116 | Noforwards bool
117 | // ID of the message
118 | ID int
119 | // ID of the sender of the message
120 | //
121 | // Use SetFromID and GetFromID helpers.
122 | FromID Peer
123 | // Peer ID, the chat where this message was sent
124 | PeerID Peer
125 | // Info about forwarded messages
126 | FwdFrom MessageFwdHeader
127 | // ID of the inline bot that generated the message
128 | ViaBotID int64
129 | // Reply information
130 | ReplyTo MessageReplyHeader
131 | // Date of the message
132 | Date int
133 | // The message
134 | Message string
135 | // Media attachment
136 | // TODO: Create a proper type for it
137 | Media json.RawMessage
138 | // Reply markup (bot/inline keyboards)
139 | // TODO: Create a proper type for it
140 | ReplyMarkup json.RawMessage
141 | // Message entities¹ for styled text
142 | //
143 | // Links:
144 | // 1) https://core.telegram.org/api/entities
145 | // TODO: Create a proper type for it
146 | Entities []json.RawMessage
147 | // View count for channel posts
148 | Views int
149 | // Forward counter
150 | Forwards int
151 | // Info about post comments (for channels) or message replies (for groups)¹
152 | //
153 | // Links:
154 | // 1) https://core.telegram.org/api/threads
155 | Replies tg.MessageReplies
156 | // Last edit date of this message
157 | EditDate int
158 | // Name of the author of this message for channel posts (with signatures enabled)
159 | PostAuthor string
160 | // Multiple media messages sent using messages.sendMultiMedia¹ with the same grouped ID
161 | // indicate an album or media group²
162 | //
163 | // Links:
164 | // 1) https://core.telegram.org/method/messages.sendMultiMedia
165 | // 2) https://core.telegram.org/api/files#albums-grouped-media
166 | GroupedID int64
167 | // Contains the reason why access to this message must be restricted.
168 | RestrictionReason []RestrictionReason
169 | // Time To Live of the message, once message.date+message.ttl_period === time(), the
170 | // message will be deleted on the server, and must be deleted locally as well.
171 | TTLPeriod int
172 | }
173 |
174 | // MessageReplyHeader represents TL type `messageReplyHeader#a6d57763`.
175 | // Message replies and thread¹ information
176 | //
177 | // Links:
178 | // 1. https://core.telegram.org/api/threads
179 | //
180 | // See https://core.telegram.org/constructor/messageReplyHeader for reference.
181 | type MessageReplyHeader struct {
182 | // Whether this message replies to a scheduled message
183 | ReplyToScheduled bool
184 | // ID of message to which this message is replying
185 | ReplyToMsgID int
186 | // For replies sent in channel discussion threads¹ of which the current user is not a
187 | // member, the discussion group ID
188 | //
189 | // Links:
190 | // 1) https://core.telegram.org/api/threads
191 | ReplyToPeerID Peer
192 | // ID of the message that started this message thread¹
193 | //
194 | // Links:
195 | // 1) https://core.telegram.org/api/threads
196 | ReplyToTopID int
197 | }
198 |
199 | // MessageFwdHeader represents TL type `messageFwdHeader#5f777dce`.
200 | // Info about a forwarded message
201 | //
202 | // See https://core.telegram.org/constructor/messageFwdHeader for reference.
203 | type MessageFwdHeader struct {
204 | // Whether this message was imported from a foreign chat service, click here for more
205 | // info »¹
206 | //
207 | // Links:
208 | // 1) https://core.telegram.org/api/import
209 | Imported bool
210 | // The ID of the user that originally sent the message
211 | FromID Peer
212 | // The name of the user that originally sent the message
213 | FromName string
214 | // When was the message originally sent
215 | Date int
216 | // ID of the channel message that was forwarded
217 | ChannelPost int
218 | // For channels and if signatures are enabled, author of the channel message
219 | PostAuthor string
220 | // Only for messages forwarded to the current user (inputPeerSelf), full info about the
221 | // user/channel that originally sent the message
222 | SavedFromPeer Peer
223 | // Only for messages forwarded to the current user (inputPeerSelf), ID of the message
224 | // that was forwarded from the original user/channel
225 | SavedFromMsgID int
226 | // PSA type
227 | PsaType string
228 | }
229 |
230 | // MessageReplies represents TL type `messageReplies#83d60fc2`.
231 | // Info about the comment section of a channel post, or a simple message thread¹
232 | //
233 | // Links:
234 | // 1. https://core.telegram.org/api/threads
235 | //
236 | // See https://core.telegram.org/constructor/messageReplies for reference.
237 | type MessageReplies struct {
238 | // Whether this constructor contains information about the comment section of a channel
239 | // post, or a simple message thread¹
240 | //
241 | // Links:
242 | // 1) https://core.telegram.org/api/threads
243 | Comments bool
244 | // Contains the total number of replies in this thread or comment section.
245 | Replies int
246 | // For channel post comments, contains information about the last few comment posters for
247 | // a specific thread, to show a small list of commenter profile pictures in client
248 | // previews.
249 | //
250 | // Use SetRecentRepliers and GetRecentRepliers helpers.
251 | RecentRepliers []Peer
252 | // For channel post comments, contains the ID of the associated discussion supergroup¹
253 | //
254 | // Links:
255 | // 1) https://core.telegram.org/api/discussion
256 | ChannelID int64
257 | // ID of the latest message in this thread or comment section.
258 | MaxID int
259 | // Contains the ID of the latest read message in this thread or comment section.
260 | ReadMaxID int
261 | }
262 |
263 | type Peer struct {
264 | UserId, ChatId, ChannelId int64
265 | }
266 |
267 | // RestrictionReason represents TL type `restrictionReason#d072acb4`.
268 | // Restriction reason.
269 | // Contains the reason why access to a certain object must be restricted. Clients are
270 | // supposed to deny access to the channel if the platform field is equal to all or to the
271 | // current platform (ios, android, wp, etc.). Platforms can be concatenated (ios-android,
272 | // ios-wp), unknown platforms are to be ignored. The text is the error message that
273 | // should be shown to the user.
274 | //
275 | // See https://core.telegram.org/constructor/restrictionReason for reference.
276 | type RestrictionReason struct {
277 | // Platform identifier (ios, android, wp, all, etc.), can be concatenated with a dash as
278 | // separator (android-ios, ios-wp, etc)
279 | Platform string
280 | // Restriction reason (porno, terms, etc.)
281 | Reason string
282 | // Error message to be shown to the user
283 | Text string
284 | }
285 |
286 | type Chat struct {
287 | // ID of the chat
288 | ID int64
289 | // Title
290 | Title string
291 | // Whether this chat indicates the currently logged in bot
292 | Self bool
293 | // Whether the account of this user was deleted
294 | Deleted bool
295 | // Is this user a bot?
296 | Bot bool
297 | // Can the bot see all messages in groups?
298 | BotChatHistory bool
299 | // Can the bot be added to groups?
300 | BotNochats bool
301 | // Whether this user is verified
302 | Verified bool
303 | // Access to this user must be restricted for the reason specified in restriction_reason
304 | Restricted bool
305 | // Whether the bot can request our geolocation in inline mode
306 | BotInlineGeo bool
307 | // Whether this is an official support user
308 | Support bool
309 | // This may be a scam user
310 | Scam bool
311 | // If set, the profile picture for this user should be refetched
312 | ApplyMinPhoto bool
313 | // If set, this user was reported by many users as a fake or scam user: be careful when
314 | // interacting with them.
315 | Fake bool
316 | //
317 | BotAttachMenu bool
318 | // Whether this user is a Telegram Premium user
319 | Premium bool
320 | //
321 | AttachMenuEnabled bool
322 | // First name
323 | FirstName string
324 | // Last name
325 | LastName string
326 | // Phone number
327 | Phone string
328 | // Version of the bot_info field in userFull¹, incremented every time it changes
329 | //
330 | // Links:
331 | // 1) https://core.telegram.org/constructor/userFull
332 | BotInfoVersion int
333 | // Inline placeholder for this inline bot
334 | BotInlinePlaceholder string
335 | // Language code of the user
336 | LangCode string
337 | // Is this a channel?
338 | Broadcast bool
339 | // Is this a supergroup?
340 | Megagroup bool
341 | // Whether signatures are enabled (channels)
342 | Signatures bool
343 | // Whether this channel has a private join link
344 | HasLink bool
345 | // Whether this chanel has a geoposition
346 | HasGeo bool
347 | // Whether slow mode is enabled for groups to prevent flood in chat
348 | SlowmodeEnabled bool
349 | // Whether this supergroup¹ is a gigagroup
350 | //
351 | // Links:
352 | // 1) https://core.telegram.org/api/channel
353 | Gigagroup bool
354 | // Whether a user needs to join the supergroup before they can send messages: can be
355 | // false only for discussion groups »¹, toggle using channels.toggleJoinToSend²
356 | //
357 | // Links:
358 | // 1) https://core.telegram.org/api/discussion
359 | // 2) https://core.telegram.org/method/channels.toggleJoinToSend
360 | JoinToSend bool
361 | // Whether a user's join request will have to be approved by administrators¹, toggle
362 | // using channels.toggleJoinToSend²
363 | //
364 | // Links:
365 | // 1) https://core.telegram.org/api/invites#join-requests
366 | // 2) https://core.telegram.org/method/channels.toggleJoinRequest
367 | JoinRequest bool
368 | // Username
369 | Username string
370 | // Whether the current user is the creator of the group
371 | Creator bool
372 | // Whether the current user has left the group
373 | Left bool
374 | // Whether the group was migrated¹
375 | //
376 | // Links:
377 | // 1) https://core.telegram.org/api/channel
378 | Deactivated bool
379 | // Whether a group call is currently active
380 | CallActive bool
381 | // Whether there's anyone in the group call
382 | CallNotEmpty bool
383 | // Whether this group is protected¹, thus does not allow forwarding messages from it
384 | //
385 | // Links:
386 | // 1) https://telegram.org/blog/protected-content-delete-by-date-and-more
387 | Noforwards bool
388 | // Chat photo
389 | Photo tg.ChatPhotoEmpty
390 | // Participant count
391 | ParticipantsCount int
392 | // Date of creation of the group
393 | Date int
394 | // Used in basic groups to reorder updates and make sure that all of them were received.
395 | Version int
396 | // Means this chat was upgraded¹ to a supergroup
397 | MigratedTo struct {
398 | // Channel ID
399 | ChannelID int64
400 | // Access hash taken from the channel¹ constructor
401 | //
402 | // Links:
403 | // 1) https://core.telegram.org/constructor/channel
404 | AccessHash int64
405 | }
406 | // Admin rights¹ of the user in the group
407 | //
408 | // Links:
409 | // 1) https://core.telegram.org/api/rights
410 | AdminRights ChatAdminRights
411 | // Default banned rights¹ of all users in the group
412 | //
413 | // Links:
414 | // 1) https://core.telegram.org/api/rights
415 | DefaultBannedRights ChatBannedRights
416 | }
417 |
418 | // ChatAdminRights represents TL type `chatAdminRights#5fb224d5`.
419 | // Represents the rights of an admin in a channel/supergroup¹.
420 | //
421 | // Links:
422 | // 1. https://core.telegram.org/api/channel
423 | //
424 | // See https://core.telegram.org/constructor/chatAdminRights for reference.
425 | type ChatAdminRights struct {
426 | // If set, allows the admin to modify the description of the channel/supergroup¹
427 | //
428 | // Links:
429 | // 1) https://core.telegram.org/api/channel
430 | ChangeInfo bool
431 | // If set, allows the admin to post messages in the channel¹
432 | //
433 | // Links:
434 | // 1) https://core.telegram.org/api/channel
435 | PostMessages bool
436 | // If set, allows the admin to also edit messages from other admins in the channel¹
437 | //
438 | // Links:
439 | // 1) https://core.telegram.org/api/channel
440 | EditMessages bool
441 | // If set, allows the admin to also delete messages from other admins in the channel¹
442 | //
443 | // Links:
444 | // 1) https://core.telegram.org/api/channel
445 | DeleteMessages bool
446 | // If set, allows the admin to ban users from the channel/supergroup¹
447 | //
448 | // Links:
449 | // 1) https://core.telegram.org/api/channel
450 | BanUsers bool
451 | // If set, allows the admin to invite users in the channel/supergroup¹
452 | //
453 | // Links:
454 | // 1) https://core.telegram.org/api/channel
455 | InviteUsers bool
456 | // If set, allows the admin to pin messages in the channel/supergroup¹
457 | //
458 | // Links:
459 | // 1) https://core.telegram.org/api/channel
460 | PinMessages bool
461 | // If set, allows the admin to add other admins with the same (or more limited)
462 | // permissions in the channel/supergroup¹
463 | //
464 | // Links:
465 | // 1) https://core.telegram.org/api/channel
466 | AddAdmins bool
467 | // Whether this admin is anonymous
468 | Anonymous bool
469 | // If set, allows the admin to change group call/livestream settings
470 | ManageCall bool
471 | // Set this flag if none of the other flags are set, but you still want the user to be an
472 | // admin.
473 | Other bool
474 | }
475 |
476 | // ChatBannedRights represents TL type `chatBannedRights#9f120418`.
477 | // Represents the rights of a normal user in a supergroup/channel/chat¹. In this case,
478 | // the flags are inverted: if set, a flag does not allow a user to do X.
479 | //
480 | // Links:
481 | // 1. https://core.telegram.org/api/channel
482 | //
483 | // See https://core.telegram.org/constructor/chatBannedRights for reference.
484 | type ChatBannedRights struct {
485 | // If set, does not allow a user to view messages in a supergroup/channel/chat¹
486 | //
487 | // Links:
488 | // 1) https://core.telegram.org/api/channel
489 | ViewMessages bool
490 | // If set, does not allow a user to send messages in a supergroup/chat¹
491 | //
492 | // Links:
493 | // 1) https://core.telegram.org/api/channel
494 | SendMessages bool
495 | // If set, does not allow a user to send any media in a supergroup/chat¹
496 | //
497 | // Links:
498 | // 1) https://core.telegram.org/api/channel
499 | SendMedia bool
500 | // If set, does not allow a user to send stickers in a supergroup/chat¹
501 | //
502 | // Links:
503 | // 1) https://core.telegram.org/api/channel
504 | SendStickers bool
505 | // If set, does not allow a user to send gifs in a supergroup/chat¹
506 | //
507 | // Links:
508 | // 1) https://core.telegram.org/api/channel
509 | SendGifs bool
510 | // If set, does not allow a user to send games in a supergroup/chat¹
511 | //
512 | // Links:
513 | // 1) https://core.telegram.org/api/channel
514 | SendGames bool
515 | // If set, does not allow a user to use inline bots in a supergroup/chat¹
516 | //
517 | // Links:
518 | // 1) https://core.telegram.org/api/channel
519 | SendInline bool
520 | // If set, does not allow a user to embed links in the messages of a supergroup/chat¹
521 | //
522 | // Links:
523 | // 1) https://core.telegram.org/api/channel
524 | EmbedLinks bool
525 | // If set, does not allow a user to send polls in a supergroup/chat¹
526 | //
527 | // Links:
528 | // 1) https://core.telegram.org/api/channel
529 | SendPolls bool
530 | // If set, does not allow any user to change the description of a supergroup/chat¹
531 | //
532 | // Links:
533 | // 1) https://core.telegram.org/api/channel
534 | ChangeInfo bool
535 | // If set, does not allow any user to invite users in a supergroup/chat¹
536 | //
537 | // Links:
538 | // 1) https://core.telegram.org/api/channel
539 | InviteUsers bool
540 | // If set, does not allow any user to pin messages in a supergroup/chat¹
541 | //
542 | // Links:
543 | // 1) https://core.telegram.org/api/channel
544 | PinMessages bool
545 | // Validity of said permissions (it is considered forever any value less then 30 seconds
546 | // or more then 366 days).
547 | UntilDate int
548 | }
549 |
550 | // ChatPhoto represents TL type `chatPhoto#1c6e1c11`.
551 | // Group profile photo.
552 | //
553 | // See https://core.telegram.org/constructor/chatPhoto for reference.
554 | type ChatPhoto struct {
555 | // Whether the user has an animated profile picture
556 | HasVideo bool `json:"HasVideo,omitempty"`
557 | // Photo ID
558 | PhotoID int64 `json:"PhotoID,omitempty"`
559 | // Stripped thumbnail¹
560 | //
561 | // Links:
562 | // 1) https://core.telegram.org/api/files#stripped-thumbnails
563 | StrippedThumb []byte `json:"StrippedThumb,omitempty"`
564 | // DC where this photo is stored
565 | DCID int `json:"DCID,omitempty"`
566 | }
567 |
--------------------------------------------------------------------------------