name
        Name of the state

    conn_id
        ID of the peering connection to delete.  Exclusive with conn_name.

    conn_name
        The name of the peering connection to delete.  Exclusive with conn_id.

    region
        Region to connect to.

    key
        Secret key to be used.

    keyid
        Access key to be used.

    profile
        A dict with region, key and keyid, or a pillar key (string) that
        contains a dict with region, key and keyid.

    .. versionadded:: 2016.11.0

    Example:

    .. code-block:: yaml

        delete a vpc peering connection:
          boto_vpc.delete_vpc_peering_connection:
            - region: us-west-2
            - conn_id: pcx-4613b12e

    Connection name can be specified (instead of ID).
    Specifying both conn_name and conn_id will result in an
    error.

    .. code-block:: yaml

        delete a vpc peering connection:
          boto_vpc.delete_vpc_peering_connection:
            - conn_name: salt_vpc_peering

def delete_vpc_peering_connection(name, conn_id=None, conn_name=None,
                                  region=None, key=None, keyid=None, profile=None):
    '''
    name
        Name of the state

    conn_id
        ID of the peering connection to delete.  Exclusive with conn_name.

    conn_name
        The name of the peering connection to delete.  Exclusive with conn_id.

    region
        Region to connect to.

    key
        Secret key to be used.

    keyid
        Access key to be used.

    profile
        A dict with region, key and keyid, or a pillar key (string) that
        contains a dict with region, key and keyid.

    .. versionadded:: 2016.11.0

    Example:

    .. code-block:: yaml

        delete a vpc peering connection:
          boto_vpc.delete_vpc_peering_connection:
            - region: us-west-2
            - conn_id: pcx-4613b12e

    Connection name can be specified (instead of ID).
    Specifying both conn_name and conn_id will result in an
    error.

    .. code-block:: yaml

        delete a vpc peering connection:
          boto_vpc.delete_vpc_peering_connection:
            - conn_name: salt_vpc_peering

    '''
    log.debug('Called state to delete VPC peering connection')
    ret = {
        'name': name,
        'result': True,
        'changes': {},
        'comment': 'Boto VPC peering state'
    }
    if conn_name:
        vpc_ids = __salt__['boto_vpc.describe_vpc_peering_connection'](
            conn_name, region=region, key=key, keyid=keyid, profile=profile).get('VPC-Peerings', [])
    else:
        vpc_ids = [conn_id]

    if not vpc_ids:
        ret['comment'] = 'No VPC connection found, nothing to be done.'
        return ret

    if __opts__['test']:
        if vpc_ids:
            ret['comment'] = 'VPC peering connection would be deleted'
        return ret

    log.debug('Called module to delete VPC peering connection')

    result = __salt__['boto_vpc.delete_vpc_peering_connection'](
        conn_id=conn_id, conn_name=conn_name, region=region, key=key,
        keyid=keyid, profile=profile)

    if 'error' in result:
        ret['comment'] = "Failed to delete VPC peering: {0}".format(result['error'])
        ret['result'] = False
        return ret

    ret['changes'].update({
        'old': '',
        'new': result['msg']
    })
    return ret