How to use AppNexus service via appnexusapi gem - ruby

I am using appnexusapi gem to connect with AppNexus api but I am not able to proceed beyond establishing a basic connection.
Here is my ruby code:
require 'appnexusapi'
conn = AppnexusApi::Connection.new({'uri' => 'http://api.appnexus.com/auth', 'username' =>'*****','password' => '******'})
key = conn.login
As the documentation is not good, I am unable to proceed further. I would like to generate reports and query the data service.
In appnexus console I found that it generates random id for every report.

To generate a report, you need to POST to the /report service with the proper json for the report you want. The easiest way to generate this json is to manually create a sample report in Console and then hit Ctrl+J to see the json used. You can then alter as necessary for your exact needs.
Once you have the json, make a POST to the /report service and you'll receive a unique report_id (for that specific report request). Using this report_id, make a GET call to the /report?id= service and look for the 'execution_status' field. When that field is 'ready', you can grab the 'url' field to get the path to actually download the data (something like /report-download?id=13828374). Make a GET to that url and you'll have all of your data.
Details are available on the AppNexus wiki if you are a client: https://wiki.appnexus.com/display/api/Report+Service

Related

Get response data from jmeter to robotframework

Please guide me whether is there any way to get the response data from jmeter to robotframework? I have integrated robotframework with jmeter and my use case is to do the data base validation using robotframework for that i want to get the unique id which i recieved in jmeter responce data.Due to some use case i cannot perform Database validation in jmeter itself.
I Dont see any keyword in the documentation,
https://kowalpy.github.io/Robot-Framework-JMeter-Library/JMeterLib.html
I don't think the plugin offers such functionality so the most straightforward way is writing your unique id into a file, depending on how you're getting the ID you can:
Use Save Responses to a file listener - it stores the whole response into a separate file
Use Sample Variables property - it adds specified JMeter Variable(s) values as a separate column(s) in the .jtl results file
Use Flexible File Writer listener where you have the full freedom to choose regarding what, where and how to store
Once done you can read the file using OperatingSystem library and do whatever you need with this ID

Why is my HTTP request URL not being generated for a Logic App?

Good morning. I am new to logic apps and I am trying to figure out how I can trigger the execution based on a GET URL with three parameters. All the examples I've found on Google show the URL being generated once the JSON and relative path is entered, but that's not happening for me. Perhaps it's because I am creating the logic app in VS.
Here's what my "When a HTTP request is received" step looks like in the logic app.
I also tried removing the JSON and just using the parameters to pass the values to the function, as shown below. I'm just not sure the best way to do this.
All I really need to do is get the three parameters into the logic app so I can perform a function call with the parameters. Any suggestions would be greatly appreciated!
Why is my HTTP request URL not being generated for a Logic App?
You need to click save, and then the url will be automatically generated for the When a HTTP request is received trigger:
You can use this expression to accept values through GET parameters:
triggerOutputs()['queries']['parameter-name']
For example:
Noteļ¼š
Queries need to pass parameters in the form of json.

Jmeter request to google

Need a help!
Using the JMeter need send request to https://www.google.com.ua/imghp?hl=ru&tab=wi&authuser=0 something like a "cat" or "dog"
and make assertion of one of the finding images.
Please help!
To do that:
Use Templates... > Recording, see this
Add the generated certificate to your browser following this documentation.
Record the thing you want to do on google
-You'll end up with :
An HTTP Request for Google Homepage
An HTTP Request for the search
To variabilize the Searched words, add a CSV Data Set
Add a Response Assertion to check the image
Use a View Results Tree to check everything is working

How to use instagram secure API requests with ruby gem?

My steps are:
update gem gem update instagram to instagram-1.1.6
add config.client_ips = "100.100.1.0" to the code (hide real ip)
check checkbox Enforce signed requests in developer page, click save
But I still get following error:
#<Hashie::Mash code=403 error_message="Invalid signed-request: Missing required parameter 'sig'" error_type="OAuthForbiddenException">
When I try to get posts or create like.
What's going wrong? What additional action needs to be done?
You use older types of signatures
On September 1, instagram only accepts new type https://instagram.com/developer/secure-api-requests/

Ruby SOAP::RPC::Driver seeing the generated soap request

I'm using ruby's WSDLFactory to create an rpc driver to access the paypoint soap service and i need to see what xml request is being generated is there a way to do this code or should i try and use something like ethereal
Use wiredump_dev= and/or wiredump_file_base=.
For example,
wiredump_dev = STDOUT will output the generated request to the console and wiredump_file_base = "/tmp/soap_log_" will append the generated request to a file named soap_log_method_name_called.log

Resources