Share this page

# LrSqsSendMessageResult.messageId

Returns the message ID.

`public final String messageId()`

## Return values

This function returns a String value that represents the message ID.

## Example

Copy code

    public int action() throws Throwable {

        String standardQueueUrl = "https://sqs.eu-central-1.amazonaws.com/123456789/jsmith-sqs0";
        String fifoQueueUrl = "https://sqs.eu-central-1.amazonaws.com/123456789/jsmith-sqsfifo0.fifo";
        LrAwsRegion region = LrAwsRegion.EU_CENTRAL_1;

        LrSqsClient.initClient(region, standardQueueUrl);

        LrSqsSendMessageResult result1 = LrSqsClient.sendMessage("hi");
        lr.output_message("message ID: " + result1.messageId());

        LrSqsClient.resetQueueUrl(fifoQueueUrl);

        result1 = LrSqsClient.sendMessage("hi", "group0", "1");
        lr.output_message("message ID: " + result1.messageId());
        lr.output_message("sequenceNumber: " + result1.sequenceNumber());

        LrSqsClient.closeClient();

        return 0;
    }

Tips to improve your search results... VuGen Function Reference Version 26.1 Function Reference 26.1 All View Local Help Center View Online Help Center Version: