Amplify API Reference - aws-amplify

I am having a really difficult time navigating the API reference. The old AWS SDK for java used to have all used classes labeled with their proper parameters, errors thrown, and return values. I am not finding this with Amplify.
Currently I am trying to understand the Amplify.storage class for Android. The closest reference I can find for it is here,
https://aws-amplify.github.io/amplify-js/api/classes/storage.html
The problem is that it does not describe the function used by their tutorial, Amplify.Storage.downloadFile()
This all seems to be the javascript implementation of this and not the java based SDK so maybe that is the problem. I've been digging around on google and I can't find anything useful, is there reference material out there that I am just not finding or is this what we have to work with?
As I dig I keep getting linked back to the tutorial which is very frustrating because I want more information than what the tutorial provides.

The Amplify Android project does not currently publish its Javadoc.
I have created an issue for this on the Amplify Android GitHub repo.
For the time-being, your best bet is to read the source code, which does contain JavaDoc. The API for the storage category is here.

Related

Firebase Cloud Firestore "Request/response" documentation

Most of "bigger" project I was working with was using REST API for Frontend->Backend communication. I was using Firebase Cloud Firestore for some small (one-day/hackathon) projects. Now I'm thinking about using Firestore for some bigger project but I'm not sure if this will work.
For "standard", REST api project I had Swagger documentation, where each developer could see list of all endpoints with request/response data structures. How does it work with Firestore? Can I create similar documentation for developers to check data structure, so they will know what can they add and what should they read? Or maybe there is another way?
I'm thinking, maybe there is no tool for this kind of documentation because frontend data structures are defining database structure? But what if I am connecting database from two or more platform (ex. web, mobile and cloud functions)? How can I synchronize knowledge about data structures between all the developers?
I was looking for some answers but couldn't find anything useful expect advice to manually maintain some documentation. How does it work in your projects? Is there some automation? Manually written documentation? Or no documentation - everything "in code"?
I understand your concerns, but unfortunately, there is no such tool available for Cloud Firestore to generate the documentation for database structure as Swagger.
I believe you can do it programatically.
From
Generating Swagger Docs in Firebase Cloud Functions project
I'm using express and nodejs in my Firebase Function implementations, and for me, Swagger doc generation can be implemented via the following libraries:.
https://github.com/scottie1984/swagger-ui-express
https://github.com/Surnet/swagger-jsdoc
You can find other libraries at:
https://swagger.io/tools/open-source/open-source-integrations
In addition to the responses there, the following service allows you to access Firestore metadata, click the explorer tab, looks promising for your use case https://aapi.io/api-directory/Google_CloudFirestore_GoogleCloudFirestoreAPI_v1beta1 though not necessarily more so than the links above.

Where can I see the SwiftPM Manifest file definition?

It started as simple as that I would like to look up all possible providers. Which ones are allowed?
However, where is the full struct definition?
There isn't a place that I am aware of where the documentation is hosted outside of the GitHub repo here.
I just dig through those and the actual implementation files if needs be to figure out what is available to me if I'm looking for/at new features.
As of WWDC 2019 there is now documentation on Apple's developer website for the package manager. It is here at the time of updating this.

Does Firebase Real-Time DB now explicitly require Google Play Services? [duplicate]

This question already has answers here:
Which firebase services require google play services on Android?
(4 answers)
Closed 4 years ago.
Background
I have an older app that still runs properly and is based on an old version of Firebase using the Real-time database functionality.
It runs on my emulator that does not have Google Services available.
Attempting To Upgrade To New Firebase
Now, I'm attempting to upgrade that code and I'm running on an emulator image that does not have Google Play services available.
Installed Firebase Via Android Studio Tools...Firebase...
I did the installation via the built-in tools from Android Studio (following the latest docs from Firebase).
The Problem
Every time the new code based on the latest version of Firebase attempts to call the following line of code I get an error (follows):
FirebaseDatabase fbd = FirebaseDatabase.getInstance();
Error Message
I get the following error:
Default FirebaseApp is not initialized in this process . Make
sure to call FirebaseApp.initializeApp(Context) first.
I'm Already Making That Call
However, I am successfully making the call to FirebaseApp.initializeApp(Context) previous to that line of code -- I've stepped thru via debugger.
Unsure About Google Services
I've seen that some say you have to add a reference to the Google Services but I'm not sure why the Firebase docs don't mention that and the built-in Android Studio tool didn't add it.
Can you point me to a definitive place in the docs where it says you need Google Services? Has anyone experienced this? Does anyone know for sure if Google Services are required?
Ok, I looked more closely at the Firebase docs (https://firebase.google.com/docs/reference/android/com/google/firebase/database/FirebaseDatabase.html#getInstance(java.lang.String))
Here's a snapshot of the info:
I'm adding that because of that odd Also: Google Play Services item. It's a link that does nothing. It isn't very helpful, but
I'm assuming it means that you do indeed need Google Play Services to be available.
This situation is odd for another reason also, and that is because the call to FirebaseApp.initializeApp(this); succeeds without error even though you can basically do nothing after that, since you will have a dependency upon Google Services for the core functionality.

Using Firebase from google instead of react-native-firebase

At the moment I am using react-native-firebase 4.3.8, but I noticed that google has updated firebase (firestore in particular), which holds some interesting new features. I was trying to use firebase from google directly, but it gives me errors (can't find variable: document) for example.
Is it possible to use firebase instead of react-native-firebase, so the updated features are available.
I know that react-native-firebase are working on an update (v5) to include those features.
To use Firebase within your React Native application you need to bind the JavaScript code to the underlying native iOS/Android SDK. When you use Invertase's react-native-firebase library they take care of that for you.
You can definitely use another library that does the same, or roll your own. But recommending a library is off-topic on Stack Overflow, and showing you how to do this yourself is a bit too broad for a question here.
If you're having problems getting the Invertase library to work, it is best if you share the minimal code that reproduces where you are stuck. That way we can see what you tried, and help you get unstuck.
If none of these apply, you will have to wait until the feature you want it available in the library. Note that Invertase's react-native-firebase library is open source, so they might be taking pull requests in case you want to help.

vuejs nativescript firebase webapp to android/ios app

I am new with NativeScript, Vue.js, and Firebase.
I have a built web app using Vue.js and Firebase, but now I don't know how to integrate the code to NativeScript using the same code of Vue.js.
Is there a way to do this? And how can I start it?
I worked with #jlooper over the last couple of weekends to get a definitive answer for this because there wasn't one anywhere previously:
https://medium.com/#groksrc/how-to-set-up-nativescript-vue-js-and-firebase-465354d4296b
There are instructions on Eddy's plugin README are mostly complete, but there are a few gotchas that I point out in my blog post that you need to be aware of. Also, the readme isn't specific to vue so it's not immediately clear where to put the Firebase files. Those are all explained in the blog post as well as a couple of links to other small projects from Jen that will get you started.

Resources