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.5.tar.gz (2.8 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.5.tar.gz.

File metadata

File hashes

Hashes for ekata-gateway-processor-helper-0.1.5.tar.gz
Algorithm Hash digest
SHA256 8cfcd0720ae9d4dd9d0cf494b3bffa9e88f43a79723a6832181a0845a25601b9
MD5 c0a6b3eebf05e7cd98159cb096061067
BLAKE2b-256 df90067baa6ce9e8936087c8f8cdcba3eab87954fea720238dbccfbe175dcc01

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ekata_gateway_processor_helper-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 d3085fcc3962960e04be8e83b7c3d7bd498e769e27af27d99176efd90082372b
MD5 7a3b6794c742e1c3cc7c02df98908c13
BLAKE2b-256 0cd865d35ae584290e3a6364483198deba6735d33c9129da7ff837086fc95f90

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