@SdkInternalApi
    final ListLinksResult executeListLinks(ListLinksRequest listLinksRequest) {

        ExecutionContext executionContext = createExecutionContext(listLinksRequest);
        AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();
        awsRequestMetrics.startEvent(Field.ClientExecuteTime);
        Request<ListLinksRequest> request = null;
        Response<ListLinksResult> response = null;

        try {
            awsRequestMetrics.startEvent(Field.RequestMarshallTime);
            try {
                request = new ListLinksRequestProtocolMarshaller(protocolFactory).marshall(super.beforeMarshalling(listLinksRequest));
                // Binds the request metrics to the current request.
                request.setAWSRequestMetrics(awsRequestMetrics);
                request.addHandlerContext(HandlerContextKey.CLIENT_ENDPOINT, endpoint);
                request.addHandlerContext(HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden());
                request.addHandlerContext(HandlerContextKey.SIGNING_REGION, getSigningRegion());
                request.addHandlerContext(HandlerContextKey.SERVICE_ID, "OAM");
                request.addHandlerContext(HandlerContextKey.OPERATION_NAME, "ListLinks");
                request.addHandlerContext(HandlerContextKey.ADVANCED_CONFIG, advancedConfig);

            } finally {
                awsRequestMetrics.endEvent(Field.RequestMarshallTime);
            }

            HttpResponseHandler<AmazonWebServiceResponse<ListLinksResult>> responseHandler = protocolFactory.createResponseHandler(new JsonOperationMetadata()
                    .withPayloadJson(true).withHasStreamingSuccessResponse(false), new ListLinksResultJsonUnmarshaller());
            response = invoke(request, responseHandler, executionContext);

            return response.getAwsResponse();

        } finally {

            endClientExecution(awsRequestMetrics, request, response);
        }
    }
<p>
Use this operation in a source account to return a list of links to monitoring account sinks that this source
account has.
</p>
<p>
To find a list of links for one monitoring account sink, use <a
href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_ListAttachedLinks.html">ListAttachedLinks</a> from
within the monitoring account.
</p>

@param listLinksRequest
@return Result of the ListLinks operation returned by the service.
@throws InternalServiceException
        Unexpected error while processing the request. Retry the request.
@throws InvalidParameterException
        A parameter is specified incorrectly.
@throws ResourceNotFoundException
        The request references a resource that does not exist.
@sample AWSOAM.ListLinks
@see <a href="http://docs.aws.amazon.com/goto/WebAPI/oam-2022-06-10/ListLinks" target="_top">AWS API
     Documentation</a>
aws-java-sdk-oam/src/main/java/com/amazonaws/services/oam/AWSOAMClient.java