Send a message to specified target (a registration token, topic or condition).
HTTP request
POST https://fcm.googleapis.com/v1/{parent=projects/*}/messages:send
The URL uses gRPC Transcoding syntax.
Path parameters
| Parameters | |
|---|---|
| parent | 
 Required. It contains the Firebase project id (i.e. the unique identifier for your Firebase project), in the format of  | 
Request body
The request body contains data with the following structure:
| JSON representation | 
|---|
| {
  "validate_only": boolean,
  "message": {
    object ( | 
| Fields | |
|---|---|
| validate_only | 
 Flag for testing the request without actually delivering the message. | 
| message | 
 Required. Message to send. | 
Response body
If successful, the response body contains an instance of Message.
Authorization scopes
Requires one of the following OAuth scopes:
- https://www.googleapis.com/auth/firebase.messaging
- https://www.googleapis.com/auth/cloud-platform
For more information, see the OAuth 2.0 Overview.