How to use the metacall.metacall_load_from_file function in metacall

To help you get started, we’ve selected a few metacall examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github metacall / examples / auth-function-mesh / auth.py View on Github external
#!/usr/bin/env python

"""MetaCall Examples - Auth Function Mesh.

[MetaCall](https://metacall.io)
[MetaCall Examples](https://github.com/metacall/examples)

This modules demonstrates a basic example of a python backend that executes
a call to another backend written in JavaScript (NodeJS).

""" 

from metacall import metacall_load_from_file, metacall

metacall_load_from_file('node', ['auth-function-mesh/auth/auth.js'])

def encrypt(text):
	return metacall('sign', text)

def decrypt(token):
	return metacall('verify', token)

metacall

A library for providing inter-language foreign function interface calls

Apache-2.0
Latest version published 2 years ago

Package Health Score

61 / 100
Full package analysis

Similar packages