Skip to content

Fatal error 404 (GET request) #558

Answered by jeromegamez
Raspberry42 asked this question in Q&A
Discussion options

You must be logged in to vote

If you search for "404" in the discussions you will find the same question having been asked twice already 😅

Please check on https://console.firebase.google.com/project/_/database/ what the name of your database is: You can find it right of the 🔗 symbol and it should look something like https://<some-string>.firebaseio.com (By default, the SDK will build this URL from the project_id field in your service account JSON file).

Once you have that URL, you can configure it in the SDK with the withDatabaseUri() method of the Factory class, so for example:

$factory = (new Factory)
    ->withServiceAccount(../firebase.json)
    ->withDatabaseUri('https://my-database-name.firebaseio.com');

$database

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@Raspberry42
Comment options

@jeromegamez
Comment options

@Raspberry42
Comment options

Answer selected by jeromegamez
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants