How to add authenticated publication url in qualtrics? - qualtrics

I am going through below post to add create event subscription.
https://api.qualtrics.com/docs/listen-to-and-retrieve-responses-in-real-time
In my case, publicationURL is protected by basic authentication, How can I subscribe to this protected url (I mean how can I convey credentials here)?
Any idea about the complete survey payload format, any documentation link helps....
Thanks,
Hari

Related

Can anyone help me to redirect to the selected country in this autocomplete form on submit?

Can anyone help me in the right direction? I am still quite new to coding.
I found this script on W3 school that I would like to adjust to my needs a little.
On submit I want to be redirected to : www.url.com/?mycountry=selectedcountry.
Is this possible and how to get there? Thanks a lot Martin
https://www.w3schools.com/howto/tryit.asp?filename=tryhow_js_autocomplete
You may add method="GET" to your <form> here is the example https://www.w3schools.com/tags/att_form_method.asp
That will help you to do the thing
The method attribute specifies how to send form-data (the form-data is sent to the page specified in the action attribute).
The form-data can be sent as URL variables (with method="get") or as HTTP post transaction (with method="post").
Notes on GET:
Appends form-data into the URL in name/value pairs
The length of a URL is limited (about 3000 characters)
Never use GET to send sensitive data! (will be visible in the URL)
Useful for form submissions where a user wants to bookmark the result
GET is better for non-secure data, like query strings in Google
Notes on POST:
Appends form-data inside the body of the HTTP request (data is not
shown in URL)
Has no size limitations
Form submissions with POST cannot be bookmarked

Symfony 4 - Send POST request with multipart/form-data

I want to send a POST request to register my users, but I don't want to type my login and password in the URL, like this. I wanted to use the multipart/form-data format, to send my arguments as if they were in a form, like that.
Do you know how can I do that?
Thanks in advance! ^^
If you want to make a POST request to some URL with some data, I suggest encoding the data in json format.
See json_encode or Symfony serializer or jms_serializer.
Or, if you wish, you can send url encoded data, using http_build_query.
Just remember to send the right Content-type header, application/json or application/x-www-form-urlencoded.
And to perform the request, consider using Guzzle or cURL.
I realize I've just provided you with official docummmentation about related stuff, but I haven't fully understood your question, so I tried giving you general pointers for you to research. There are good examples of certain functionallities I believe you will need in order to do this.
Assuming you have the URL to make the request:
gather the data to post
serialize the gathered data
execute the request to the url with the serialized data
parse the response body
continue doing your logic
In case this isn't what you were looking for, please provide some more context, some code you have (don't share any sensitive data), or something, so you could get more precise answers. I hope I've managed to help. Feel free to ask more questions.
Okay I used $request->request->get() to extract my values , like this :
$entityManager = $this->getDoctrine()->getManager();
$user = new User();
$user->setLogin($request->request->get('login'));
$user->setPassword($request->request->get('password'));
$entityManager->persist($user);
$entityManager->flush();
And then I serialize my values in a JSON object, it's working perfectly ^^ Thanks for your help! ^^

How to set expiration time for a link sent via Email?

I send a link as email to the users asking them to reset the password. Clicking on the link redirects to a page in my project. How can I set the expiration time for this link to 24 hours, and how do I know if this link is not re-used again? Whats the best way to do this?
Thanks
I dont know how your process looks like but the recommend way is to use a guid to identify the
passwort reset process.
This is how a process should look like.
Create a database table with the userId, createDate, closeDate, and a guid
Create a new entry in the table
Send the mail with a link to your page that has the uuid from the entry
If the user enters the page (clicks the link) you check if the process is still open (closeDate is null)
Check if the createDate is within the last 24 hours
User can change password
You set the closeDate
store email sent date&time in the database(where your maintaning userdetails) .
when your are open link for reset password capture present date. compare both date&time values . they you can procced. may this helps you.
I have an idea
Create a Time.now() and encrypt this using encryption and attach with your link
Send using Email and other option
go to the link page
write code on page load Request the sent encrypted Date Time and decipher it
match time if time is over then send to an error page else continue
Like -:- http://Yourhost/foldername.aspx?val=encryptedTimeDate

Link formation in a third-party .aspx website

I want to understand what link is formed when I click print button on http://recruitment.cdacmohali.in/TETPB/Regprintagain.aspx
Sample data is 2011360220 and 25/05/1980
I want to integrate it with my website and get the url it it making so that in the url I can pass the registration number and dob as variable and see the complete results.
I think it is using Session. You can not pass the data by QueryString

Passing a Session Variable via a URL (ASP.Net)

I have an aspx page, which is a "User Log-In" area. I want to pass the userid to another page which is linked from the aspx page.
the link I have looks something like this:
www.abcdefg.com/Home/Redirect/?authtkn=123456abcd=xxxx
I need the xxxx to be a session variable which in this case is userid.
**userid is not sensative information, this is simply to redirect the user to another page for specified information.
Any thoughts on how to pass a session variable to a URL, or if this can be done. The example www.abcdefg.com is a different domain (on a different server) from the original aspx page.
Why not appending like this?
string.Format("www.abcdefg.com/Home/Redirect/?authtkn=123456abcd={0}",
Session["UserId"]);
if i understood you correctly.
Think your question is how to maintain cross domain session or authentication.
Check this link Maintaining Session State Across Domains, may give you some idea
Or this one How can I share a session across multiple subdomains?
You don’t need to pass a session variable via the url. You can just start session on the next page and have access to all your session variables! If you do want the variables up there so you can quickly get to different userids with just a quick url change, send userid to the url on your previous page with with $_GET[ ].

Resources