

# Amazon RDS API reference
<a name="ProgrammingGuide"></a>

In addition to the AWS Management Console and the AWS Command Line Interface (AWS CLI), Amazon RDS also provides an API. You can use the API to automate tasks for managing your DB instances and other objects in Amazon RDS. 
+ For an alphabetical list of API operations, see [Actions](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_Operations.html).
+ For an alphabetical list of data types, see [Data types](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_Types.html).
+ For a list of common query parameters, see [Common parameters](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/CommonParameters.html).
+ For descriptions of the error codes, see [Common errors](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/CommonErrors.html).

For more information about the AWS CLI, see [AWS Command Line Interface reference for Amazon RDS](https://docs.aws.amazon.com/cli/latest/reference/rds/index.html). 

**Topics**
+ [

# Using the Query API
](Using_the_Query_API.md)
+ [

# Troubleshooting applications on Amazon RDS
](APITroubleshooting.md)

# Using the Query API
<a name="Using_the_Query_API"></a>

The following sections briefly discuss the parameters and request authentication used with the Query API.

For general information about how the Query API works, see [Query requests](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Query-Requests.html) in the *Amazon EC2 API Reference.*

## Query parameters
<a name="query-parameters"></a>

HTTP Query-based requests are HTTP requests that use the HTTP verb GET or POST and a Query parameter named `Action`.

Each Query request must include some common parameters to handle authentication and selection of an action. 

Some operations take lists of parameters. These lists are specified using the `param.n` notation. Values of *n* are integers starting from 1. 

For information about Amazon RDS Regions and endpoints, go to [Amazon Relational Database Service (RDS)](https://docs.aws.amazon.com/general/latest/gr/rande.html#rds_region) in the Regions and Endpoints section of the *Amazon Web Services General Reference*.

## Query request authentication
<a name="query-authentication"></a>

You can only send Query requests over HTTPS, and you must include a signature in every Query request. You must use either AWS signature version 4 or signature version 2. For more information, see [ Signature Version 4 signing process](https://docs.aws.amazon.com/general/latest/gr/signature-version-4.html) and [ Signature version 2 signing process](https://docs.aws.amazon.com/general/latest/gr/signature-version-2.html).

# Troubleshooting applications on Amazon RDS
<a name="APITroubleshooting"></a>

Amazon RDS provides specific and descriptive errors to help you troubleshoot problems while interacting with the Amazon RDS API.

**Topics**
+ [

## Retrieving errors
](#RetrievingErrors)
+ [

## Troubleshooting tips
](#TroubleshootingTipss)

 For information about troubleshooting for Amazon RDS DB instances, see [Troubleshooting for Amazon RDS](CHAP_Troubleshooting.md). 

## Retrieving errors
<a name="RetrievingErrors"></a>

Typically, you want your application to check whether a request generated an error before you spend any time processing results. The easiest way to find out if an error occurred is to look for an `Error` node in the response from the Amazon RDS API.

XPath syntax provides a simple way to search for the presence of an `Error` node. It also provides a relatively easy way to retrieve the error code and message. The following code snippet uses Perl and the XML::XPath module to determine if an error occurred during a request. If an error occurred, the code prints the first error code and message in the response. 

```
use XML::XPath; 
    my $xp = XML::XPath->new(xml =>$response); 
    if ( $xp->find("//Error") ) 
    {print "There was an error processing your request:\n", " Error code: ",
    $xp->findvalue("//Error[1]/Code"), "\n", " ",
    $xp->findvalue("//Error[1]/Message"), "\n\n"; }
```

## Troubleshooting tips
<a name="TroubleshootingTipss"></a>

 We recommend the following processes to diagnose and resolve problems with the Amazon RDS API:
+ Verify that Amazon RDS is operating normally in the AWS Region that you're targeting by checking [http://status.aws.amazon.com](http://status.aws.amazon.com/).
+ Check the structure of your request.

  Each Amazon RDS operation has a reference page in the *Amazon RDS API Reference*. Double-check that you are using parameters correctly. For ideas about what might be wrong, look at the sample requests or user scenarios to see if those examples do similar operations.
+ Check AWS re:Post.

  Amazon RDS has a development community where you can search for solutions to problems others have experienced along the way. To view the topics, go to [AWS re:Post](https://repost.aws/).