title: AWS API Gateway DynamoDB GetItem without sort key?
body: <p>I've a Dynamo Db table with following</p>
  
  <pre><code>{
    "primary_key": {
      "S": "series"
    },
    "sort_key": {
      "S": "type-of-brokers"
    },
    "title": {
      "S": "Types Of Brokers"
  }
  ,
  {
    "primary_key": {
      "S": "series"
    },
    "sort_key": {
      "S": "type-of-brokers-2"
    },
    "title": {
      "S": "Types Of Brokers-2"
  }
  </code></pre>
  
  <p><a href="https://sanderknape.com/2017/10/creating-a-serverless-api-using-aws-api-gateway-and-dynamodb/" rel="noreferrer">Following this</a> I've implemented application/json body mapping template:</p>
  
  <pre><code>{
      "TableName": "table_name",
      "Key" :{
          "primary_key" :{
              "S": "series"
          },
          "sort_key" : {
              "S": "type-of-brokers"
          }
      }
  }
  </code></pre>
  
  <p>It returns one item that matched primary and sort key!</p>
  
  <p>Now I want to <strong>return all the matched <code>primary_key</code> items i.e. without <code>sort_key</code></strong></p>
  
  <p>How do I achieve that? with API gateway body mapping template?</p>
  
  <p>Also, can api return common json rather than "S" kind, <a href="https://sanderknape.com/2017/10/creating-a-serverless-api-using-aws-api-gateway-and-dynamodb/" rel="noreferrer">here it specify attributes</a> , can it be done by not hard coding in <code>integration response</code> </p>