How to call Amazon API Gateway in LibGDX? - amazon-web-services

I'm developing a game for iOS and Android using LibGDX. I would like to use Amazon Web Services and I haven't found if there is a library or a way to access API Gateway from my (:core) project.
I've worked with API Gateway in Android and iOS native projects and is very easy to implement it because Amazon has SDK Generation for both platforms. But since there's not a way to export for Java, it seems to bee a little tricky to make api calls from the core project.
I tried to use amazon skd for android inside (:core) but it didn't worked.
May be making a direct Http request using HttpURLConnection, but I don't know how to do it and although it won't map the response objects.

I don't have specific experience with LibGDX, but API Gateway helps you generate REST based APIs. There are a number of Java libraries that will help you interact with REST based APIs, such as rest4j. As you note, you will have to either forgo using API Gateway's Models or build your own marshalling code on top whatever solution you use for interacting with your API.

Related

How do I generate a .NET Standard client SDK based on RestAPI in AWS API Gateway?

Ive read within documents that AWS RestAPIs within the API Gateway service supports automating the process of generating SDK's.
I'd like to generate a .NET Standard library based off of an API that is contained within RestAPI (which had swagger doc used for generating docs/method)
How exactly can I auto-generate (by way of scripts) .NET standard library based on an ASP.NET Core WebAPI which is using swagger and has been placed behind RestAPI front-end?
Does AWS support .NET Standard?
What other methods of automatically generating the SDK should I consider to do the job? Any insight is appreciated, fundamentally I really liked the idea of auto generating a client sdk based on api documentation based off of swagger. And those customers I would like to do it for have heavy use of .net.
Note: Im not looking for java , javascript , android , objectivec (for iOS), swift (for iOS), and ruby. Specifically, I am looking for .net.
I have used NSwag.CodeGeneration.CSharp to generate .NET clients from swagger definition. Here is my code I used for my AWS re:Invent presentation last year. https://github.com/aws-samples/cloudmosaic-dotnet/tree/reinvent-2019/Application/Clients/CloudMosaic.API.Client.Generator

YouTube Player API with Exposed GCP API keys

Recently I received this Alert in the Google Play Console
Your app contains exposed Google Cloud Platform (GCP) API keys
I am using the YouTubeApi Player, and I believe the only why you can initialize it is using this line of code
youTubePlayer.initialize(DEVELOPER_KEY, this);
So beside added restrictions to my API key, is there any other way to remove the API Key from the code?
I tried using the GCP service accounts as suggested by Google, but I do not see how I can still use the YouTube Player without the initialize line of code.
I have same problem, and fixed this by using string R.string.google_api_key generated by google_services.json
change your code to:
youTubePlayer.initialize(getString(R.string.google_api_key), this);
how to get google_services.json:
create firebase project https://firebase.google.com/docs/android/setup?hl=id
get your google_services.json https://support.google.com/firebase/answer/7015592?hl=id
There are some tips on how to secure your API keys at Using API Keys documentation.
It is stated that embedding API keys directly in the code should be avoided, which is the way you are having it right now, therefore you are getting the warning message.
Follow the tips on that page and you should properly secure your API key. As soon as you do so, the warning will go away.
UPDATE
To avoid having a long discussion in comments, allow me to elaborate further providing this update.
Google provides different ways of authentications to give you more options for securing your apps based on your needs. The warnings are helpful tips to make your apps more secure when going in production or exposing to public. So in your case, it would be better to use a different way of authentication.
API keys can be used in server side. e.g. If you are using an API key to authenticate a 3rd party service from an App Engine app, you can use this key as you already have it, since it is impossible for the key to get exposed. (Avoid using API keys in JavaScript since inspecting the page in the browser will expose the API key as well)
In your case, since you are developing an Android app and/or an iOS app, having the API key in the code is dangerous. Because, anyone can use the .apk or the .ipa file and find a way to access it. Therefore, for developing Android apps and iOS apps it is suggested going with different authentication method. The other authentication method supported in YouTube player API is using OAuth 2.0. For more information you can check the Registering your application documentation.

How Should I integrate Amazon RDS in Flutter? Any native dart support package?

how to use AWS RDS in flutter dart code?
I went through - this post
It says -
I work on the AWS SDK team. I am not aware of any plans to support Flutter at this point. I will take this to my team as a feature request and will post back
Should I do as suggested here?
Build your own service layer using HTTP, gRPC that talks to some backend service that provides access to a data store. You can do this with Express, Rails, CloudFunctions, etc.
You can either use dart code to do HTTP/gRPC, or use Platform channel to wrap dart code around native iOS and Android code of AWS official SDK.
On another note, I'm highly concerned when you connect directly from mobile (Flutter) to database (AWS RDS). Please be aware that anything on mobile app can be reversed engineer, and your database connection credential is not safe. It's recommended to have only backend proxy, or at least severless (such as AWS lambda function) connect directly to database (not mobile or web frontend). The only exception is with Firebase Realtime Database because it has seamless integration with Firebase Authentication

Federate a c++ client application with openam or opensso

We have a c++ client application that a user authenticates and connects to the server using its credential through the client. Is there any way to implement SSO module for it to communicate with OpenAM?
There is two possible way to implement this:
using the C agent SDK to perform authentication and do session management -> you may find that the C SDK isn't that pleasant and potentially too much tied to web servers in certain aspects. Also the C SDK uses the legacy OpenAM endpoints, which will potentially mean that in the future you will most likely need to adapt your code to use a newer version of the SDK that uses the REST interfaces
use the new REST APIs directly. The REST interfaces are still evolving though, hence they are subject of changes. In 12.0.0 there will be an API versioning solution though, which should mean that existing REST clients can remain to use the "old" version of the REST API.

Invoking a web service API by using Text Message

Now I am creating an iOS application. I also implemented some web services. My requirement is : "The user should be able to call a web service API by Sending a Text Message(SMS)". After a lot of research I found out that there a provider called Clickatell(http://www.clickatell.com/). But I don't know how can I configure it? Please help me in configuring this. Or Is there any other APIs or SMS gateways providing this service?
Disclaimer, I do developer evangelism part time at Nexmo.
Here are a few SMS APIs that I've used (I've not really used Clickatell, but I've gone through the signup process, and the following APIs seem a lot simpler to use):
Nexmo
Twilio
Tropo
All three APIs are straight forward REST/HTTP APIs.
You can call the API directly from your mobile application, however, you should consider if you really want to then compile your API credentials into your application. It may be better to host a kind pf proxy that your application uses - here's some example code used as a verification service, but it's essentially the same concept: https://github.com/Nexmo/Verify
I would suggest to take a look at Mogreet's new Developer Web Site
Very easy to use REST/HTTP APIs and very powerful. It supports sending SMS/MMS with awesome quality for all media types.