How to pass additional parameters to this twitter update api by using curl from terminal?
http://twitter.com/statuses/update.xml
Say I need to pass replyto user id as given in the documentation. Although I could simply append #username before the message, I need user id based and #user_id didn't work.
We need to simply append it to the url.
http://twitter.com/statuses/update.xml?in_reply_to_status_id=12345
Related
I have two page
Login/Registration Page as of now
OTP Verification Page
API has been created and in api, we are passing phone number as request and gets otp as response. However i would like your help to know how should i able to pass the phoneNumber textfield data to APIcall json request in flutterflow?
If there is anyway or any documentation will be really helpful?
I have tried with variable method, however i was not able to pass it to json.
I have also tried jsonpath method, but no luck.
Define dynamic part of API url with brackets
https://jsonplaceholder.typicode.com/posts/[postId]
https://jsonplaceholder.typicode.com/comments?postId=[postId]
then create the variable (postId) with the same name. When adding the API call, it is required to add these variables.
See API Calls 101 for details.
I have a rails application in which I would like to generate a url based on a parameter, but for that parameter to be hidden from public view. So essentially working like a POST request but being able to be typed in like a GET request.
For example using a QR reader I could have the address as www.site.com/qr?lot_no=18007 but when a user scans the QR image it only shows www.site.com/qr but displays the results related to lot_no=18007.
Not sure if this is possible or not. But any help would be greatly appreciated.
If all you want to do is to prevent it from showing up in the address bar of the browser, you could use Rails.ajax to make the request dynamically through Javascript.
That will at least hide it from casual inspection, but there is no way to suppress the parameters from the query string on a GET completely, so anyone looking at the Networks tab in the browser (for example) would still see them.
Another alternative would be to encrypt the parameter value.
Maybe the Friendly id gem may be of help here
The following is an example of it's use is
http://example.com/states/washington
instead of:
http://example.com/states/4323454
This is not going to work with a post request as you mention though. It is a way of using a get request that would normally send an id in the params hash to retrieve existing records.
The gem can be found here https://github.com/norman/friendly_id
It is well maintained and up to date
Configure different route for public facing URL, the URL should include encrypted lot id as a path param.
routes.rb
get '/view_lot/:id' => 'QrCodesController#view_lot`, as: :public_view_lot
now in QrCodesController add action view_lot
def view_lot
encrypted_id = params[:id]
id = decrypt_it(encrypted_id)
#lot = Lot.find(id)
render "your_template"
end
in you QR code generation, pass URL to above action with encrypted id like public_view_lot_url(lot_id)
I have an issue on where i cannot get the parameters to pass through via url.
Below is the url to the report i want to pass a single ID parameter (#ID).
I have tried a few ways, first time in passing via URL.
Any help grateful.
http://rpt.Server.local/Reports/Pages/Report.aspx?ItemPath=%2f%5bQuality+Sales+Report%5d%2fCP+Quailty+Sales+Details+Report+Preview&ViewMode=Detail
http://rpt.Server.local/Reports/Pages/Report.aspx?ItemPath=%2f%5bQuality+Sales+Report%5d%2fCP+Quailty+Sales+Details+Report+Preview&ViewMode=Detail
instead of above link try below
Go to http://rpt.Server.local/Reportserver
find your report in above link and pass "&ID=(value) at the end of the url
or
http://rpt.Server.local/Reportserver/Pages/Report.aspx?ItemPath=%2f%5bQuality+Sales+Report%5d%2fCP+Quailty+Sales+Details+Report+Preview&ID=(value)
I have a task to add row into Google Sheet when WebHook received. Now I'm trying to setup IFTTT but have some problem
It says that I should use URL like https://maker.ifttt.com/trigger/{event}/with/key/{my_key} and that is ok I can do it. But it needs to send some data in request and the only way my system can do it appends it to query string like https://maker.ifttt.com/trigger/{event}/with/key/{my_key}?name1=Alex&name2=Helen
But IFTTT doesn't see my data. it says that it can see data in attached JSON but I can't use JSON.
So is there any way to pass my data to IFTT in a query string or shell I forgot IFTTT and investigate how to connect directly to Google Sheet?
IFTTT Maker webhooks can only take data with keys of "value1", "value2", and "value3". Try sending it with:
https://maker.ifttt.com/trigger/{event}/with/key/{my_key}?value1=Alex&value2=Helen
Try using https://bitly.com/ which will shorten and convert the query params to a path param. That worked for me.
First thing first, Web hooks are designed to accept data using POST method only and here you are sending data using GET, which is obviously not going to work, i guess.
Second, in order to get it work, one way is to use cURL request and send your JSON in Body with POST method.
I am creating a custom slash command that hooks up to a RESTful API. I am looking to send a user id of the current users choosing, so I'd love to be able to use the # shortcut to bring up the list of teammates. This API call is expecting a user id and a message. Is something like this possible:
/SLASHCOMMAND #USER, MESSAGE
You can certainly type #whatever into a a slash command, but the text will just be sent as-is to your HTTP endpoint.
In the example above, you would receive "#USER, MESSAGE" as the text of the slash command. (If you want an ID, you'll then have to do your own parsing to find at-mentions and use the Slack Web API to figure out the ID corresponding to that username.)