Skip to main content

Backend helper functions for ekata gateway processor

Project description

Ekata Gateway Processor backend helper functions

Create form id

Use this function to create a form id from your backend, if successful it will return form_id and created_on.

    from ekata_gateway_processor_helper import create_payment_form
    from ekata_gateway_processor_helper.exceptions import (
        InvalidAPIKeyException, InvalidProjectException, NoEnabledCurrencyException,
        InvalidArgumentsException
    )

    try:
        form_id, created_on = create_payment_form(
            amount=int(Decimal(amount) * 100) # Always provide in atomic amount of fiat currency,
            fiat_currency='USD',
            project_id='',
            api_key=''
        )
    except InvalidProjectException as e:
        print(e.message)
    except InvalidAPIKeyException as e:
        print(e.message)
    except NoEnabledCurrencyException as e:
        print(e.message)
    except InvalidArgumentsException as e:
        print(e.arguments)

Verify payment payload

Use this function to verify payment payload received after successful payment

    from ekata_gateway_processor_helper import verify_payload
    if verify_payload(
        payload='' # payload received from frontend or webhook,
        signature_secret='' #payment signature secret
        ):
        # Proceed with checkout, like send success message to frontend etc

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ekata-gateway-processor-helper-0.1.7.tar.gz (3.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file ekata-gateway-processor-helper-0.1.7.tar.gz.

File metadata

File hashes

Hashes for ekata-gateway-processor-helper-0.1.7.tar.gz
Algorithm Hash digest
SHA256 696fee3842977a90a9fb73c9f21a3d291ffe4e3b03e785b5384b244fb4373494
MD5 548e8869c1eda792129036e8a742f4e5
BLAKE2b-256 fa248983b77aabf0a8e51b9fa046856e4658eaee98ed9c624cb57f5a28f1f170

See more details on using hashes here.

File details

Details for the file ekata_gateway_processor_helper-0.1.7-py3-none-any.whl.

File metadata

File hashes

Hashes for ekata_gateway_processor_helper-0.1.7-py3-none-any.whl
Algorithm Hash digest
SHA256 8113659eedcee4ed9460c181a19298ec416e1af482079466bf439d45f4a942c7
MD5 baa69930acf8c7043ffd632e32d8304f
BLAKE2b-256 d2a48e6b27618a808ef488a3a5359b01587d96275d4c758d068fc871e312005c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page