Exemplo n.º 1
0
def _cancel_process_for_international(**payload):
    """Process a cancel request by imp_uid"""
    iamport = Iamport(config.IAMPORT_API_KEY_FOR_INTERNATIONAL,
                      config.IAMPORT_API_SECRET_FOR_INTERNATIONAL)

    try:
        result = iamport.cancel_by_imp_uid(**payload)
        return True, result,
    except Exception as exception:
        return _process_exception(exception)
Exemplo n.º 2
0
def _cancel_process_for_domestic(**payload):
    """Process a cancel request by imp_uid"""
    iamport = Iamport(config.IAMPORT_API_KEY_FOR_DOMESTIC,
                      config.IAMPORT_API_SECRET_FOR_DOMESTIC)

    try:
        result = iamport.cancel_by_imp_uid(**payload)
        return True, result,
    except Exception as exception:
        return _process_exception(exception)