# 30127: MessagingServiceSID is invalid.

Log Type: APPLICATION

Log Level: ERROR

## Description

`MessagingServiceSID` is invalid when the value you provide does not match a valid Messaging Service SID. Messaging Service SIDs are 34-character identifiers that start with `MG`.

### Possible causes

* You passed a `MessagingServiceSID` value that does not use the `MG` prefix or does not contain 32 hexadecimal characters after the prefix.
* The SID does not identify a Messaging Service resource.
* You copied the SID from the wrong account or from an unrelated resource. This is an inference based on how Twilio uses SIDs to identify specific resources.

### Possible solutions

* Replace the value with a valid Messaging Service SID from the Services resource or Console. Use a SID that matches `^MG[0-9a-fA-F]{32}$`.
* If you are creating a message, send the SID in the `MessagingServiceSid` parameter. Twilio lets you send a message with `MessagingServiceSid` instead of `From`.
* Make sure the Messaging Service exists and belongs to the account making the request. Twilio identifies Messaging Service resources with SIDs, and the Messages resource requires the sender to belong to the creating account.

#### Additional resources

* [Messages resource](/docs/messaging/api/message-resource)
* [Services resource](/docs/messaging/api/service-resource)
