Does Zuora Provide Test API Methods/ Data to Simulate Errors? - zuora

I've been through Zuora's docs and a number of sites named "sandbox" but I cannot find a reference to a way to simulate errors in a manner like Stripe and others provide. Does such a page exist?

Related

Github Automerge Failure Notification (API v4 GraphQL mutation enablePullRequestAutoMerge)

at my company we want to make use of the relatively new API feature "Automerge" (not through a UI but through an API call),
However we can't seem to find any documentation of a webhook (or other asyc way) of finding out if a merge request failed and why,
anyone know a way to receive such a notification?
Thanks! :)
Hope this saves some work for someone out there,
we asked Github.com support directly and they said there was no async / webhooky way of doing this (as of Nov 2021).
Here's a quote from the support person when asked if there were a way to find out, here's what they wrote:
There wouldn't be a great way to discern that (reason for failure) and
it may be better when you see that, to use the REST API to Get the
Pull Request to get some additional information.
looking at the documentation as suggested in the quote above it seems that through the "closed" action and "merged" key one could discern whether a merge was successful or not, but without any further information about the failure.

Looking up values in html in background of iOS app

I'm new to iOS development and I'm trying to make an app that tracks my student loans. I would like to have the app simply display a balance found on the loan's website and build on that behavior. I've got my app to open up safari to the website but I'd like more of a web-crawling behavior so it's done in the background. This web-crawler needs to be able to login to the website and then find a field with the loan balance value..
I've looked up several ways on how to do this but I can't get any of them to work with my novice level of experience with swift. If anyone has a recommendation and a direction to go with this, that would be great.
Thanks in advance!
I've written an app to get my uni's schedules, payment records, and grades by bypassing the login and gain access to API used by the website.
The step you could take are probably very similar to mine
Find out how the website authenticate its users (could be by cookie, session id's etc) You need to have some knowledge on web too. You can use the network tab on Chrome/Brave/Safari or any other browser to see what the website is doing when you click on 'login' for example. You could use Charles too, 30 days of trial should be enough.
After authentication succeed, track what API route the website use to get the datas to html. See what information you need to access the API route. Postman would be very handy to see the JSON response by the API.
To parse the response, you can use URLSession or networking library like Alamofire to get the job done.
If you want to see how I did it, here's the GitHub repo.

Retrieve list of (discovered) fields using Cloudwatch Logs SDK

On the documentation page for Supported logs and Discovered fields, we can see an overview of what fields Cloudwatch might discover. How can I detect what fields my logstream contains using the SDK?
I know such functionality must exists, as you can see a nice little list of your discovered fields when using the Insights dashboard on the AWS Cloudwatch UI:
After posting my question, I looked at the documentation one more time and found the method that I needed: getLogGroupFields.

Is there anyway to convert or import AIML files to Dialogflow or Lex?

Is there anyway to convert or import AIML files to Dialogflow or Lex for creating a chatbot? I am hoping for a way to incorporate open source AIML files into an NLP chatbot framework like Dialogflow or Lex, and so far my googling has produced no avail.
I found a way to create a Dialogflow bot using CSV, and I wonder if this is a case of converting AIML into CSV? Is it feasible or a fool's errand?
Much appreciation for your advice, guidance, and brainstorming!
Keith Sterling has a way listed on his github page using python 3. It also has a full step-by-step implementation with screenshots and was just updated a few days ago. It’s AIML 2.1 compliant as well.
Also, it is completely free. DialogFlow itself has both free and paid tiers (as you may know) but his program is open source.
Here’s the link:Program-Y github Repo
By way of background, this is an AIML Interpreter (which is to say it is a way for you to deploy your AIML files under various circumstances). So while the link in the OP is more direct, this gives you more options.
For example this allows you to use your same files in:
Google Assistant
A Web Client
Messenger
Telegram
Alexa
Cortana
DialogFlow
etc
And because this is REST you only interact with your main implementation and this in-turn updates all client bots.
This helps you keep an updated central set of AIML files and is also lower on overhead.
Set-up:
First sign in and then click Create Agent.
Give you bot a name, and ensure the language and timezone is what you need them to be, and then click:
Create Intents
First, delete the 2 existing intents:
Default Fallback
Default Welcome
Next, create the intents for integration with Program-y (the name of the Repo).
There are 4:
Launch
Quit
Help
Query
Launch Intent
Click Create Intent
Enter your training phrases
select event, and then,
under fulfillment, choose web-hook
Quit Intent
Carry out the same steps as above, this time naming it Quit, but this time do not select an Event and use the following phrases:
stop
exit
leave
quit
Help Intent
Again carry out the same steps as above, this time naming it Help. Again do not select an Event and use the following phrases:
help
what can I ask you
help me
what can you do
Query Intent
Finally carry out the same processes, but this time name it Query. Again do not select an Event, but this time we have one training phrase
query
This time, however, add a parameter as follows:
Connect Endpoint
Finally we need to set the endpoint that DialogFlow will call each time it identifies an intent.
On the left hand side menu bar, click Fulfillment link. Click Enabled and then enter the URL that should be called which Program-Y is running on as a Google client.
The API endpoint is always /api/alexa/v1.0/ask So combine this with the ngrok URL, gives you https://87e27269.ngrok.io/api/alexa/v1.0/ask
To save this click 'Save Endpoints' and you are ready to get your client up and running.
Scroll down to the bottom and click Save.
I know that’s a lot of info and it may look overwhelming however there are screenshots and a walkthrough at the link:
Program-Y github Repo
No, currently there is no way to do this. There is no straightforward way to translate AIML files to Dialogflow or Lex JSON import formats. The basic structure of how the conversation is handled is different. Although you can find the idea of Intent, Entities and Context in AIML (specially v2.0) you would need to do a lot of manual effort to adapt it.
I would recommend extracting the patterns -what the user says- and the templates -what the chatbot responds- from AIML, import it to the framework you want to use and adapt manually the context and entities.

obfuscate json from webserver

I've got an android and iphone app that both get the required data from a webserver. The data is sent via json to the client. Using this setup other people might simply retrieve the url the app is calling and this way could make use of the data that I gather with my scripts on the server. To make it short: I don't want that :)
My idea is to make the json unreadable for example by encrypting it. This would make it a little harder to retrieve the information since this way some who would like to use my service would had to decompile the app an lookup any decryption stuff I had implemented.
Therefore two questions:
Do there exist some libraries that already offer such a functionality (Server side is Java)?
Does anyone of you have any other suggestions how I could protect my api from unwanted guests?
Thanks in advance :)
I think the options available would be...
to lock down the API to Authorized/Authenticated users.
Using BSON to obfuscate the data.
You could always use oAuth to allow the users to authenticate based on an account they already have: Facebook, Twitter, Google etc.