NATION

PASSWORD

[question] regarding userclick parameters

Bug reports, general help, ideas for improvements, and questions about how things are meant to work.
User avatar
Sweeze
Spokesperson
 
Posts: 161
Founded: Oct 21, 2018
Left-Leaning College State

[question] regarding userclick parameters

Postby Sweeze » Sun Jul 03, 2022 8:07 pm

heya! i know that as things are it's encouraged for scripts that perform restricted actions (and thus operate off of human input) to include a user timestamp for the user input that triggered the request to ns. the example linked, however, includes said timestamp as a URL parameter, but i know that's also what has to be done for browser extensions in substitute of including the useragent in a header. however, since i'm using the requests module with python, i can send whatever parameters and headers i want, so to my main question:
would it be preferred for a userclick timestamp to be included as a header or a url parameter?
| lily supreme command | the mt army third in command | dev of swarm and feather |
[6:38 PM] Chingis: ... the Tom Brady of R/D
5417+ times tag/detag delegate, 5945+ regions hit, only person to become delegate of 200+ regions in an update (multiple times)
she/they

User avatar
Esfalsa
Secretary
 
Posts: 35
Founded: Aug 07, 2015
Civil Rights Lovefest

Postby Esfalsa » Sun Jul 03, 2022 11:29 pm

With client-side JavaScript, User-Agent must be sent as a URL parameter because Chrome will silently drop it if included as a header. But if memory servers, no such limitations should affect a custom userclick header. Just wanted to piggyback off of Sweeze's question briefly and ask if the answer would be the same regardless of the language/platform used or if it would differ (e.g. for Python vs JavaScript).

User avatar
[violet]
Site Admin
 
Posts: 15723
Founded: Antiquity

Postby [violet] » Mon Jul 04, 2022 5:54 pm

Sweeze wrote:would it be preferred for a userclick timestamp to be included as a header or a url parameter?

It will be ignored as a header, so don't bother with that. It will be ignored by me as an URL parameter, too, since I have no way of verifying that number, but I understand Elu has suggested it might be helpful in some circumstances.

Esfalsa wrote:ask if the answer would be the same regardless of the language/platform used

Same answer either way. Also note that officially scripts must always send a UserAgent header with contact info -- we understand that some can't do this due to technical limitations, in which case an URL parameter is the next best thing, but it's not a user preference; you must configure a header if possible.


Return to Technical

Who is online

Users browsing this forum: Fragmentation

Advertisement

Remove ads