Skip to main content

No project description provided

Project description

Magic API

The Magic API!

  1. incr the toml version
  2. poetry publish --build

For CLI:

Magic CLI (magicapi has this built in)

The best server maker.

Steps:

  1. pip install magicapi (make sure the pip points to the correct python (3.6+))

  2. cd into the directory you want the server to be in

// use the cli to create the app

  1. magic create < app name >

  2. cd < app name >

// now make the virtual env and pip install the requirements 5) python3 -m venv venv

  1. source venv/bin/activate

  2. pip install -r requirements.txt

  3. pip install --upgrade magicdb magicapi

// files needed to run 8) Create an .env file in the < app name > directory.

a) Use the ".example_env" as a template. Fill in the env variables for the services you will need to use.

b) The SERVICE and TASKS_TABLE_NAME are required for the app.

// add firestore

  1. add the firestore service account json to the < app name > and name it "my-service-account.json"

// to deploy to aws lambda

  1. Create a user on AWS and sign in via the CLI (https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-quickstart.html)

  2. npm i

  3. magic deploy

That should be it for the setup!

Time to run it!

To start a local server: magic start

To test local server (while local server is running): magic test

To deploy for the first time or any time you change the serverless yaml: magic deploy

To deploy when you just edited the app code: magic deploy_again

To update magicapi: pip install --upgrade magicapi

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

magicapi-0.1.79.tar.gz (17.7 kB view details)

Uploaded Source

Built Distribution

magicapi-0.1.79-py3-none-any.whl (25.3 kB view details)

Uploaded Python 3

File details

Details for the file magicapi-0.1.79.tar.gz.

File metadata

  • Download URL: magicapi-0.1.79.tar.gz
  • Upload date:
  • Size: 17.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.0.10 CPython/3.8.2 Darwin/19.6.0

File hashes

Hashes for magicapi-0.1.79.tar.gz
Algorithm Hash digest
SHA256 94fb84d7a608918938d4dc12f89d8ae25fecdaf24c936cfe90f8e149efbed46c
MD5 13391c0c973b2132bf3909a00c5ae161
BLAKE2b-256 60bbf4985ce4bc990313169de2a2211e45483b828b2a28ae0406836e0b2a8b80

See more details on using hashes here.

File details

Details for the file magicapi-0.1.79-py3-none-any.whl.

File metadata

  • Download URL: magicapi-0.1.79-py3-none-any.whl
  • Upload date:
  • Size: 25.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.0.10 CPython/3.8.2 Darwin/19.6.0

File hashes

Hashes for magicapi-0.1.79-py3-none-any.whl
Algorithm Hash digest
SHA256 b4404e477106b2db249ca1ff190791e1802b9837abf1ee16c1eff78cd0fb56b7
MD5 27b6084c54bcee079c865fedeec34f86
BLAKE2b-256 a3db4a4ccc86f95f526c40b5b444aa40a9a12a379a255a115f0a3d05594d385d

See more details on using hashes here.

Supported by

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