<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def remove_api_gateway():
 """Remove the Blockade REST API service."""

    logger.debug("[#] Removing API Gateway")
    client = boto3.client('apigateway', region_name=PRIMARY_REGION)
    matches = [x for x in client.get_rest_apis().get('items', list())
               if x['name'] == API_GATEWAY]
    if len(matches) == 0:
        logger.info("[!] API Gateway already removed")
        return True
    match = matches.pop()
    response = client.delete_rest_api(
        restApiId=match.get('id')
    )
    logger.info("[#] Removed API Gateway")

    return response