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.6.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.6.tar.gz.

File metadata

File hashes

Hashes for ekata-gateway-processor-helper-0.1.6.tar.gz
Algorithm Hash digest
SHA256 60ef60c6ccc6b7205d3e662ab0008538f2e7e3ebf174b9bf97d14d45990e52e2
MD5 19cbc5897a8c50ea88e4dc1d98a6fa5c
BLAKE2b-256 3371a5b69e4ce963e2b32434f8720a7131a523479f8f6650781b46428bc0668b

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ekata_gateway_processor_helper-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 0c9ed1b112bd59616204e4fdc4853c3baea5304a27dd463a05976b2bd0fb04e0
MD5 4945d196e76ce185a84db0672b392144
BLAKE2b-256 58d74e8612ddba733bbee255fa078d1c04ce3c8f6a00e1e7aaf7824c61796053

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