Early access · launching soon. Request access

Early access

Early access · launching soon
Product
IntelligenceEarly access. Designed and in development. No results yet. See what's left on the roadmap.
Developers
Resources
Request access

A person reads every request.

Get startedEarly accessDesigned and in development. No results yet. See what's left on the roadmap.

Quickstart: create a project and send a test push

Oricato Team Last updated SDK 1.0.1

Early access · launching soon. This guide takes you from an empty dashboard to a test notification on your own phone. You create a project, connect your Firebase project, add the Oricato SDK to your app and watch the setup checklist tick itself off.

The examples use a sample app called Lingora (com.lingora.app). Use your own app’s name, application ID and bundle ID. New to terms like project, subscription or receipts? See Key concepts.

Prerequisites

  • A dashboard login with the Admin or Owner role. Only admins and owners can create projects and upload Firebase keys. Oricato is in early access. If you don’t have a login yet, request access.
  • An app that already uses Firebase Cloud Messaging, with google-services.json (Android) or GoogleService-Info.plist (iOS) from its Firebase project. Oricato sends through that Firebase project.
  • Admin rights in that Firebase project, so you can create a service account key.
  • For iOS: your APNs authentication key (.p8) uploaded in Firebase console → Project settings → Cloud Messaging → Apple app configuration.
  • A real phone. iOS needs a real device for this test. On Android, an emulator with Google Play services can also receive FCM, but a real phone is the most reliable test. Install a debug build of your app on it.
  • SDK kit 1.0.1, which contains the Android, iOS and Flutter SDKs and their integration guides.

Steps

1. Create the project

  1. In the dashboard, create a new project. The project wizard has five steps: Name, Platforms, Firebase key, Add to your app and Check it works.
  2. Name your app. Enter the App name (up to 80 characters, for example Lingora). Only you and your team see it. You can also pick a fallback emoji and the Default language, which people get when their language has no translation.
  3. Where does your app run? Choose Android, iOS, or Android and iOS, then select Create project. You can change this later.

Create one project per app. The Android and iOS builds of the same app share one project and one Project ID. Don’t create a separate project per platform.

After you select Create project, you can leave the wizard at any time. The project exists and shows Finish setup until you complete it. If you leave on the first step, nothing is created.

2. Upload your Firebase key

Oricato sends through your app’s own Firebase project with a service account key that only the Oricato server keeps.

  1. Open the Firebase console and pick your app’s Firebase project.
  2. Go to Project settings → Service accounts → Manage service account permissions (this opens Google Cloud console → IAM & Admin → Service Accounts) and select Create service account. Create a dedicated service account (the dashboard suggests the name oricato-push-sender) with only the role Firebase Cloud Messaging API Admin. Don’t use the default key from Generate new private key: that account can do far more than send messages.
  3. Open the service account → Keys → Add key → Create new key → JSON. A .json file downloads.
  4. Back in the wizard, select Choose the .json file and pick that file.

The server checks the key before it stores anything: it validates the file, gets an access token from Google, and dry-runs a send to your project’s recently seen devices. If the check fails, nothing is stored and the dashboard tells you why. For the full walkthrough, including the exact IAM role and how to rotate keys, see Firebase and APNs credentials.

iOS: confirm that your APNs key (.p8) is uploaded in Firebase → Project settings → Cloud Messaging. Oricato’s iOS notifications travel through Firebase to APNs, so without that key every iOS send fails.

3. Copy your Project ID and API address

The wizard’s Add Oricato to your app step shows both values, and the setup code there already has them filled in. You can find them again later in Project → Settings → Add Oricato to your app, or in the Your app’s details panel of Finish setup (Verify setup once setup is complete).

Value What it looks like Notes
Project ID A UUID, for example 0192e1aa-1111-7c22-8d33-445566778899 One per app.
API address https://api.oricato.com No path and no trailing slash. Only your servers add /api/v1 for REST calls.

In the code below, replace <ORICATO_PROJECT_ID> and <ORICATO_API_ADDRESS> with these two values.

4. Add the SDK to your app

Add the SDK from the kit as described in your platform’s SDK quickstart, then add the minimal code below. Call initialize on every app start. It is idempotent and cheap.

Android (Kotlin). Add implementation("com.oricato:push:1.0.1") from the kit’s local Maven repository, then initialize in Application.onCreate:

class App : Application() {
    override fun onCreate() {
        super.onCreate()
        Oricato.initialize(
            this,
            projectId = "<ORICATO_PROJECT_ID>",
            apiBaseUrl = "<ORICATO_API_ADDRESS>",
            defaultSmallIcon = R.drawable.ic_stat_notification, // optional, white-on-transparent
        )
    }
}

Declare the SDK’s messaging service in app/src/main/AndroidManifest.xml, inside <application>. This is required: without it, your app never receives Oricato pushes.

<service
    android:name="com.oricato.push.OricatoMessagingService"
    android:exported="false">
    <intent-filter>
        <action android:name="com.google.firebase.MESSAGING_EVENT" />
    </intent-filter>
</service>

If your app already has its own FirebaseMessagingService, keep it and forward to the SDK instead. The Android quickstart shows how, along with the status-bar icon and the res/raw/oricato_keep.xml resource file.

iOS (Swift). Add the OricatoPush Swift package to your app target, then initialize in didFinishLaunchingWithOptions and pass the FCM token from your Firebase MessagingDelegate:

import UIKit
import FirebaseCore
import FirebaseMessaging
import OricatoPush

@main
class AppDelegate: UIResponder, UIApplicationDelegate, UNUserNotificationCenterDelegate, MessagingDelegate {

    func application(
        _ application: UIApplication,
        didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
    ) -> Bool {
        FirebaseApp.configure()
        Messaging.messaging().delegate = self

        Oricato.initialize(projectId: "<ORICATO_PROJECT_ID>", apiBaseURL: "<ORICATO_API_ADDRESS>")

        UNUserNotificationCenter.current().delegate = self
        application.registerForRemoteNotifications()
        return true
    }

    // Firebase → Oricato: called at every start and whenever the FCM token changes.
    func messaging(_ messaging: Messaging, didReceiveRegistrationToken fcmToken: String?) {
        Oricato.setFCMToken(fcmToken)
    }
}

Your app also needs the Push Notifications capability, Background Modes → Remote notifications, and the two Oricato.userNotificationCenter calls in your notification delegate so taps are reported as opens. The iOS quickstart has the complete AppDelegate and the optional Notification Service Extension.

Flutter (Dart). Add oricato_push from the kit to pubspec.yaml, then register a top-level background handler and initialize in main:

import 'package:firebase_core/firebase_core.dart';
import 'package:firebase_messaging/firebase_messaging.dart';
import 'package:flutter/material.dart';
import 'package:oricato_push/oricato_push.dart';

import 'firebase_options.dart';

@pragma('vm:entry-point')
Future<void> firebaseMessagingBackgroundHandler(RemoteMessage message) async {
  if (await Oricato.handleBackgroundMessage(message)) return;

  // … your own background handling for other pushes …
}

Future<void> main() async {
  WidgetsFlutterBinding.ensureInitialized();
  await Firebase.initializeApp(options: DefaultFirebaseOptions.currentPlatform);
  FirebaseMessaging.onBackgroundMessage(firebaseMessagingBackgroundHandler);

  await Oricato.initialize(
    '<ORICATO_PROJECT_ID>',
    '<ORICATO_API_ADDRESS>',
    options: const OricatoInitOptions(
      defaultSmallIcon: 'ic_stat_notification',
    ),
  );

  runApp(const MyApp());
}

The Flutter quickstart covers the Android desugaring setup, the iOS capabilities and apps that already use firebase_messaging or flutter_local_notifications themselves.

5. Ask for notification permission

Android 13 and newer and all iOS versions need the person’s permission before notifications appear. Ask once, at a moment that makes sense in your app:

// Android: from an Activity
Oricato.requestPermission(activity) { granted -> /* update your UI */ }
// iOS
Oricato.requestPermission()
// Flutter
final status = await Oricato.requestPermission();

If your app already shows a permission prompt (your own or another SDK’s), keep it and don’t add a second one. The SDK reports a permission granted from any prompt as soon as your app is back in front.

6. Check it works with the setup checklist

  1. Install the build on your phone, open the app once and allow notifications.

  2. In the dashboard, open the project → Finish setup (called Verify setup once setup is complete). The wizard’s last step, Check it works, shows the same checklist. It updates itself every few seconds.

  3. Wait for each item to tick:

    • Firebase key works: the dashboard shows the Firebase project the key is connected to.
    • Your app connected: shows that your phone registered, for example “Android phone registered 1 minute ago.”
    • Phone found: your phone appears with its model, language and country, and its notification permission. If the phone uses a different Firebase project than your key, the warning appears here.
  4. Under Send a test notification, select Send test notification. It sends “It works!” to this phone only and isn’t counted in your statistics. Follow the timeline:

    State What it means
    Queued Waiting to send.
    Sent to Firebase Handed to Firebase.
    Arrived on the phone The phone reported that it received it.
    Opened Someone tapped it.
  5. Tap the notification on your phone. Tapping is the real test: some phones can’t report arrival, so a test can stay at Sent to Firebase and still be on your screen. After 30 seconds without arrival, the dashboard says “Some phones can’t report arrival. If you see the notification, tap it — that’s the real test.”

  6. Under Keep this phone for testing, give the phone a name and select Mark as test device. From now on, test sends from the message composer go to your test devices first.

Verify it works

  • The setup checklist reaches Opened and shows “Everything works. Your app is ready to send notifications.”
  • Your phone appears in Audience, and under Audience → Test devices after you mark it.
  • The subscription ID that your app reports matches the one in the dashboard. Log it and search for it in Audience:
Log.d("OricatoDemo", "Subscription: ${Oricato.getSubscriptionId()}")

Troubleshooting

“This phone uses Firebase project Y, but your key is for X”

Your app and your key belong to different Firebase projects, so notifications won’t arrive. Either upload the key of the phone’s Firebase project, or replace the app’s google-services.json or GoogleService-Info.plist with the one from the project your key belongs to.

When you upload a key for a different Firebase project than your earlier key or your devices use, the server answers 409 firebase_project_mismatch and the dashboard asks you to type the new Firebase project ID to confirm. Only confirm if you are deliberately switching Firebase projects.

Your phone never appears in the checklist

  • Android: the manifest doesn’t declare the messaging service. Add the com.oricato.push.OricatoMessagingService service from step 4, or forward from your own FirebaseMessagingService. This is the most common cause on Android.
  • Android: the FCM token is null, or the log shows Firebase Installations “BAD CONFIG”. Your Firebase Android API key is restricted to Android apps but doesn’t list your app’s package name and SHA-1 certificate fingerprint. In Google Cloud console → APIs & Services → Credentials, open the Android key and add your package name with the SHA-1 of every certificate that signs your app (debug, upload and Play App Signing).
  • “Wrong Project ID” or “The Oricato API answered 404” in the SDK log. The Project ID or API address passed to initialize is wrong, and the API answers HTTP 404. The SDK stops calling until the next app start. iOS and Flutter log “Wrong Project ID” for any 404. Android logs “Wrong Project ID” only when the server doesn’t know the project; any other 404, such as a wrong apiBaseUrl, logs “The Oricato API answered 404 (…). Check apiBaseUrl.” Copy both values again from Add Oricato to your app. To see the SDK log, call Oricato.setLogLevel(OricatoLogLevel.DEBUG) on Android (filter logcat by Oricato), Oricato.setLogLevel(.debug) on iOS (filter Console.app by subsystem com.oricato.push) or Oricato.setLogLevel(OricatoLogLevel.debug) in Flutter.
  • The phone registered before you opened the checklist. Select Look further back to include phones from the last hour, day or week.
  • initialize isn’t called on start. Close the app completely and open it again after you add the code.

The iOS test fails with apns_auth_error

The dashboard shows “APNs key missing or invalid in Firebase”. Upload a valid APNs authentication key (.p8) in Firebase console → Project settings → Cloud Messaging → Apple app configuration, then send another test.

The test is sent but nothing shows on the phone

  • Check that notifications are allowed for the app. The Phone found row shows the phone’s permission state, for example “Notifications are blocked on this phone — allow them in the phone’s settings, then reopen the app.”
  • If the test stays at Sent to Firebase, look at the phone anyway. Some phones can’t report arrival, so tap the notification if you see it.
  • Some Android manufacturers’ system software (for example TECNO HiOS) can demote notifications to silent. Check the app’s notification settings on the phone.

For more fixes, see Troubleshooting delivery.

Next steps

Related

Get early access to Oricato.

Founding teams get early access, free help moving from OneSignal, and a founding discount.

We use this to reply, plan your invitation and set up your account. Privacy Policy

A person reads every request.

Or get the monthly newsletter