Firebase Admin Go SDK Release Notes

To review release notes for the Firebase console and for other Firebase platforms and related SDKs, refer to the Firebase Release Notes.

Version 4.14.1 - 30 May, 2024

Authentication

  • Fixed an issue that caused the verifyIDToken() and verifyIDTokenAndCheckRevoked() APIs to throw an error when the cache headers lacked expiry time for public certificates.

Version 4.14.0 - 10 April, 2024

  • Dropped support for Go versions 1.17, 1.18, and 1.19. The Admin Go SDK now requires Go 1.20 or higher.

Cloud Messaging

  • Added the FCMOptions field to the MulticastMessage type. Thanks FZambia for the contribution.

Version 4.13.0 - 23 November, 2023

Cloud Storage

  • Mapped Firebase FIREBASE_STORAGE_EMULATOR_HOST to Cloud API's STORAGE_EMULATOR_HOST.

Authentication

  • Added the TotpInfo field to UserRecord type.

Version 4.12.1 - 25 September, 2023

Authentication

Version 4.12.0 - 12 July, 2023

Cloud Messaging

  • Added sendEach() and sendEachForMulticast() APIs.

  • sendAll() and sendMulticast() APIs are now deprecated. Use sendEach() and sendEachForMulticast() APIs instead.

Version 4.11.0 - 06 April, 2023

  • The SDK now requires module mode to build the current version of the library.

Authentication

  • Added TOTP as a multi-factor option in project and tenant configuration.

Version 4.10.0 - 10 November, 2022

Realtime Database

  • The Realtime Database API now supports running against Firebase emulator suite. Enable the emulator mode by setting the FIREBASE_DATABASE_EMULATOR_HOST environment variable to point to the emulator Realtime Database endpoint. Thanks r-LaForge for the contribution.

Firebase App Check

  • Added a new app_check.verify_token() API to verify App Check tokens. Thanks bamnet for the contribution.

Version 4.9.0 - 06 October, 2022

  • Dropped support for Go versions 1.15 and 1.16. Admin Go SDK now requires Go 1.17 or higher.

Authentication

  • Fixed an incorrect key used to set MemoryCost config in StandardScrypt type.

Version 4.8.0 - 06 April, 2022

  • Dropped support for Go versions 1.11 to 1.14. The Admin Go SDK now requires Go 1.15 or higher.

Authentication

  • Added support for enabling or disabling anonymous authentication through tenant configuration. Thanks sonatard for the contribution.

Version 4.7.1 - 20 January, 2022

Authentication

  • Prevented serializing unspecified fields as empty strings in the auth.UserProvider type.

Version 4.7.0 - 15 December, 2021

Authentication

  • Added support for configuring the authorization code flow for OIDC providers.

Version 4.6.1 - 04 November, 2021

  • The Admin SDK no longer retries RPCs that fail with HTTP 500 internal server errors. For certain services, retrying on HTTP 500 errors is not idempotent. The SDK will continue to retry RPCs that fail with HTTP 503 unavailable errors.

Authentication

  • The VerifyIDTokenAndCheckRevoked() and VerifySessionCookieAndCheckRevoked() APIs now throw an error if the user record is disabled.

Version 4.6.0 - 02 June, 2021

Authentication

  • The Admin SDK now supports ID token verification when operating in emulator mode. Thanks maku693 for the contribution.
  • Added a new IsEmailNotFound() error checking function for handling the errors returned by the email action link generator functions.
  • Fixed the ability to import users with partial user metadata. You can now import a user with only CreationTimestamp in UserMetadata. Thanks valery-barysok for the contribution.

Cloud Messaging

  • Fixed an error with unmarshalling AndroidNotificationPriority. Thanks parnic for the contribution.

Realtime Database

  • Added support for Realtime Database instances hosted in non-US regions. Thanks thameezb for the contribution.

Version 4.5.0 - 14 April, 2021

Authentication

Version 4.4.0 - 29 March, 2021

Authentication

  • Added a new GetUserByProviderUID() function to look up user accounts by their providers.
  • The GetUserByProviderID() function introduced in the previous release has been deprecated in favor of the new GetUserByProviderUID() function.

Version 4.3.0 - 24 March, 2021

Authentication

  • The UpdateUser() function now supports linking a federated ID with a user account.
  • Added a new GetUserByProviderID() function to look up user accounts by their providers.

Version 4.2.0 - 28 January, 2021

Authentication

  • The Admin SDK now supports the Authentication emulator. Developers can configure the SDK to run against the emulator by setting the FIREBASE_AUTH_EMULATOR_HOST environment variable. Thanks maku693 for the contribution.

Version 4.1.0 - 22 October, 2020

Authentication

  • Implemented support for specifying password-salt order in hash configurations used when importing users.
  • Migrated the token signing functionality to the new IAM credentials API.

Version 4.0.0 - 16 June, 2020

  • The Admin SDK has opted into Go modules. The package name now has the major version appended to it. Developers should use the new package name firebase.google.com/go/v4 when installing and importing the SDK. See the Go Admin SDK v4 migration guide for more details.
  • Added a new errorutils package that provides functions for checking for platform-level error codes.

Authentication

  • Added new service-level error checking functions IsIDTokenInvalid(), IsIDTokenExpired(), IsSessionCookieInvalid(), IsSessionCookieExpired() and IsCertificateFetchFailed(). These functions can be used in conjunction with the existing JWT verification APIs.

Cloud Messaging

  • The messaging.WebpushFcmOptions type has been renamed to messaging.WebpushFCMOptions.
  • Added new service-level error checking functions IsThirdPartyAuthError(), IsQuotaExceeded(), IsSenderIDMismatch(), IsUnregistered() and IsUnavailable().

Version 3.13.0 - 21 May, 2020

Authentication

  • Added GetUsers() and DeleteUsers() APIs for retrieving and deleting user accounts in bulk.
  • Implemented support for creating custom tokens scoped to specific tenants. CustomToken() and CustomTokenWithClaims() functions are now also exposed on the auth.TenantClient type.

Version 3.12.1 - 23 April, 2020

  • Deferred credential loading until required, which allows some APIs like auth.VerifyIDToken() to be called without credentials.

Cloud Messaging

  • Updated the remote endpoint used by topic management operations. Thanks rueian for the contribution.

Version 3.12.0 - 15 January, 2020

Cloud Messaging

Authentication

  • Fixed a bug in the TenantIterator type which was preventing it from listing all the tenants correctly.

Version 3.11.1 - 23 December, 2019

Authentication

  • Minor improvements to the implementation to fix the API reference output generated by godoc.

Version 3.11.0 - 18 December, 2019

  • Dropped support for Go 1.9 and 1.10. The Admin SDK for Go now requires Go 1.11 or higher. Thanks shogo82148 for the contribution.

Authentication

  • Added a new IsInvalidEmail() error checking function. Thanks shogo82148 for the contribution.
  • Added auth.TenantManager API for creating, updating, retrieving, and deleting authentication tenants.
  • Added auth.TenantClient API for managing users, configuring SAML/OIDC providers, and generating email action links for specific tenants.

Cloud Messaging

  • Batch messaging APIs SendAll() and SendMulticast() now support sending up to 500 messages in a single call.

Version 3.10.0 - 30 October, 2019

Authentication

  • auth.ExportedUserRecord no longer exposes password hashes that are redacted due to lack of permissions in the service account credentials.
  • Added auth.OIDCProviderConfig type and the related functions to create, retrieve, update and delete OIDC auth provider configurations.
  • Added auth.SAMLProviderConfig type and the related functions to create, retrieve, update and delete SAML auth provider configurations.

Cloud Messaging

  • Added support for sending an image URL with notifications. Thanks chemidy for the contribution.

Version 3.9.0 - August 07, 2019

Cloud Messaging

  • Added the SendAll() API for sending multiple notifications as a batch.
  • Added MulticastMessage and SendMulticast() APIs for sending notifications to multiple recipients.
  • Added support for specifying the analytics label for notifications via AndroidFCMOptions, APNSFCMOptions and FCMOptions types. Thanks chemidy for the contribution.

Version 3.8.1 - June 11, 2019

  • Fixed some unit tests that were failing in environments without Google Application Default credentials.

Version 3.8.0 - May 30, 2019

Authentication

  • Added APIs for creating links for password reset, email verification and email link sign-in via auth.PasswordResetLink(), auth.EmailVerificationLink() and auth.EmailSignInLink(). See Generating Email Action Links for more details and code samples.
  • All APIs in the auth package now automatically retry RPC calls failing due to I/O or HTTP errors.

Version 3.7.0 - March 28, 2019

  • Enabled automatic HTTP retries for the APIs in db, messaging and iid packages.

Authentication

Version 3.6.0 - January 16, 2019

Cloud Messaging

  • The messaging.Aps type now supports configuring a critical alert sound. A new messaging.CriticalSound type has been introduced for this purpose.
  • Public types in the messaging package now support correct JSON unmarshalling.

Authentication

  • The VerifyIDToken() function now tolerates a clock skew of up to 5 minutes when comparing JWT timestamps.

Version 3.5.0 - December 04, 2018

  • Dropped support for Go 1.8 and earlier.

Cloud Messaging

  • messaging.AndroidNotification type now supports specifying a channel_id when sending messages to Android O devices. Thanks chemidy for the contribution.
  • messaging.ApsAlert type now supports specifying a subtitle. Thanks chemidy for the contribution.
  • messaging.WebpushNotification type now supports specifying additional FCM options. Thanks chemidy for the contribution.
  • Improved error handling by requesting a more verbose error response from the FCM backend service.

Realtime Database

  • Fixed how the SDK handles special characters in node names.

Version 3.4.0 - September 13, 2018

Realtime Database

  • firebase.App provides a new DatabaseWithURL() function that can be used to initialize clients that connect to different database instances in the same Firebase project.

Version 3.3.0 - August 9, 2018

Authentication

  • Fixed a regression introduced in the 3.2.0 release, where VerifyIDToken() cannot be used in Google App Engine.

Cloud Messaging

Version 3.2.0 - July 17, 2018

  • The Admin SDK can now read the Firebase/Google Cloud Platform project ID from both GCLOUD_PROJECT and GOOGLE_CLOUD_PROJECT environment variables.

Authentication

  • The Admin SDK can now create custom tokens without being initialized with service account credentials.
  • The SDK now provides a ServiceAccountId option specifier, which can be used to set just the client email of a service account.
  • When deployed in an environment managed by Google (e.g. Google App Engine), the SDK can auto discover a service account ID without any explicit configuration.

Version 3.1.0 - June 12, 2018

  • The iid package now provides a set of new functions for checking various error conditions such as iid.IsInvalidArgument(), iid.IsNotFound(), etc.

Authentication

  • A new ImportUsers() function for importing users to Firebase Auth in bulk.
  • UpdateUser() and DeleteUser() functions now correctly return a UserNotFound error when called with a non-existing user ID.

Version 3.0.0 - May 8, 2018

  • CustomToken(), CustomTokenWithClaims() and VerifyIDToken() functions now take a Context as the first argument.

Version 2.7.0 - April 17, 2018

  • The auth and messaging packages now provide a set of new functions for checking various error conditions (for example, auth.IsIDTokenRevoked(), messaging.IsInvalidArgument() etc).

Cloud Messaging

  • Added the MutableContent field to the messaging.Aps type. This can be used to set the mutable-content property when sending FCM messages to APNs targets.
  • Added support for specifying arbitrary key-value fields in the Aps type.
  • Improved error handling in the messaging API. The returned errors now contain additional details.

Version 2.6.1 - March 15, 2018

Cloud Messaging

Version support

  • Support for go version 1.6.

Version 2.6.0 - February 28, 2018

Realtime Database

  • A new db package that facilitates basic data manipulation operations (create, read, update and delete), conditional updates (transactions) and advanced queries. Currently, this API does not support realtime event listeners.

Version 2.5.0 - February 14, 2018

Cloud Messaging

  • A new messaging package for sending FCM messages and managing topic subscriptions.
  • A new Send() function for sending FCM messages.
  • A new SubscribeToTopic() function for subscribing a list of device registration tokens to a FCM topic.
  • A new UnubscribeFromTopic() function for unsubscribing a list of device registration tokens from a FCM topic.

Authentication

Version 2.4.0 - January 11, 2018

Initialization

  • The firebase.NewApp() method can now be invoked without any arguments. This initializes an app using Google Application Default Credentials, and firebase.Config loaded from the FIREBASE_CONFIG environment variable.

Authentication

  • The user management operations in the auth package now uses the identitytoolkit/v3 library.
  • The ProviderID field on the auth.UserRecord type is now set to the constant value firebase.

Version 2.3.0 - December 21, 2017

  • A new InstanceID API that facilitates deleting instance IDs and associated user data from Firebase projects.

Version 2.2.1 - December 13, 2017

Authentication

  • Adding the X-Client-Version to the headers in the API calls for tracking API usage.

Version 2.2.0 - December 08, 2017

Authentication

  • A new user management API that supports querying and updating user accounts associated with a Firebase project. This adds GetUser(), GetUserByEmail(), GetUserByPhoneNumber(), CreateUser(), UpdateUser(), DeleteUser(), Users() and SetCustomUserClaims() functions to the auth.Client API.

Version 2.1.0 - November 07, 2017

Version 2.0.0 - October 13, 2017

Authentication

  • The Auth() API now accepts a Context argument. This breaking change enables passing different contexts to different services, instead of using a single context per App.

Version 1.0.2 - September 13, 2017

Authentication

  • When deployed in the Google App Engine environment, the SDK can now leverage the utilities provided by the App Engine SDK to sign JWT tokens. As a result, it is now possible to initialize the Admin SDK in App Engine without a service account JSON file, and still be able to call CustomToken() and CustomTokenWithClaims().

Version 1.0.1 - September 07, 2017

Authentication

  • Now uses the client options provided during SDK initialization to create the http.Client that is used to fetch public key certificates. This enables developers to use the ID token verification feature in environments like Google App Engine by providing a platform-specific http.Client using option.WithHTTPClient().

Version 1.0.0 - August 30, 2017

  • Initial release of the Admin Go SDK. See Add the Firebase Admin SDK to your Server to get started.
  • You can configure the SDK to use service account credentials, user credentials (refresh tokens), or Google Cloud application default credentials to access your Firebase project.

Authentication

  • The initial release includes the CustomToken(), CustomTokenWithClaims(), and VerifyIDToken() functions for minting custom authentication tokens and verifying Firebase ID tokens.