Skip to content

An application containing a list of stories (like Instagram posts) uploaded by users from Dicoding Story API. This app is made for final submission on the "Android Intermediate" (Belajar Pengembangan Aplikasi Android Intermediate) Dicoding course.

Notifications You must be signed in to change notification settings

Riofuad/User-Story-App

Repository files navigation

Dicoding: User Story App 📱

Dicoding Logo

An application containing a list of stories (like Instagram posts) uploaded by users from Dicoding Story API. In this app, you can upload story with image (from camera and gallery), description, and location (optional), you can also see other user story in list (and in Google Map view also!) in realtime, and if you click one of the story you can see the detail of the story. This app is made for final submission on the "Android Intermediate" (Belajar Pengembangan Aplikasi Android Intermediate) Dicoding course. This application implements some of the material from the course, i.e:

  • Advanced UI (Custom View)
  • Animation (Shared Animation)
  • Localization and Accessibility (Languages and Text-to-speech)
  • Media (CameraX, Gallery Intent, Upload File to Server)
  • Geo Location (using Google Maps API)
  • Include Advanced Testing (Unit and UI Test using Espresso)
  • Advanceed Database (RawQuery, Room, Database Migration, Paging3 with RemoteMediator)

This application is based on endpoint API base URL https://story-api.dicoding.dev/v1/ with several routes in use, i.e.:

  • .../login for login
  • .../register for register or create account
  • .../stories for get all list stories and upload story with or without location (lat and lon params)
  • .../stories?location=1 for get story list based on location in Google Map view

This application uses Kotlin as a programing language and Android Studio version Electric Eel as a tool for developing the app.

Get Google Map API Key 🗺

To display the Google Map view, you need the API Key from Google Cloud Console. Here is the step to get your own Google Map API key:

  1. First, enter the Google Cloud Console and open the Credentials tab.
  2. Check and click AGREE AND CONTINUE to agree to the Terms of Service.
    note: If you are asked to enter a billing account, you can follow the other alternatives in step number 10. The important thing is to understand the basic steps first.
  3. Then go to the side menu and select API & Services → Credentials.
  4. Create a new project by clicking CREATE PROJECT and change the project name to your liking. Click CREATE to continue.

    note: Remember that the limit for the number of projects that can be created is 12. If you already have 12 projects, delete one of the projects first or you can use an existing project.
  5. Next, activate the Google Maps feature by selecting Enabled APIs & Services on the side menu and clicking the + ENABLED APIS AND SERVICES button.
  6. A variety of features will appear that you can use in the Google Cloud Console. Select Maps SDK for Android and click Enable.
  7. Next, select the Credentials menu on the side menu and click the CREATE CREDENTIALS → API key button to create new credentials.
  8. At this point, you have got the key which usually starts with the word "AIza…". Actually you can use this API key, but this key is still not secure because any project can use it. To be more secure, click the Edit API key link.
  9. Select the Android apps checkbox in Application restrictions and add new data by clicking ADD AN ITEM. Then fill in the package name of your application and the SHA-1 of the device used.

    note: Each device has a different SHA certificate. To get the SHA-1, you can run the gradlew signingreport or ./gradlew signingReport command in the Android Studio Terminal.
  10. Apart from using the method above, you can also create an APIKey via a direct link like this to make it even faster.
    https://console.developers.google.com/flows/enableapi?apiid=maps_android_backend&keyType=CLIENT_SIDE_ANDROID&r=11:22:33:44:55:66:77:88:99:00:AA:BB:CC:DD:EE:FF:01:23:45:67%3Bcom.packagename.appname
    You only need to change the SHA-1 data and package name marked in bold.

Note: The above steps are taken based on the "Geo Location" module of that Dicoding course.

⚠ Disclaimer ⚠

This repository is created for sharing and educational purposes only. Plagiarism is unacceptable and is not my responsibility as the author.

About

An application containing a list of stories (like Instagram posts) uploaded by users from Dicoding Story API. This app is made for final submission on the "Android Intermediate" (Belajar Pengembangan Aplikasi Android Intermediate) Dicoding course.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages