Skip to main content

This is the simplest module for quick get project endpoints

Project description

Endmapper

Endmapper is a library for mapping endpoints.

Installation

pip install endmapper

Config file "cmapcfg.json"

{
  //This keywords must be in path
  "path_white_list": [],
  //This keywords could not be in path
  "path_black_list": [],
  //This keywords must be in endpoint name 
  "name_white_list": [],
  //This keywords could not be in endpoint name
  "name_black_list": [],
  //Services use with proxy endpoints
  //Service what you want to connect must use endmapper too
  "services": {
    "endpoint_name": "hostname or ip"
  }
  
  //You can use fields from .env
  "services": {
    "endpoint_name": "${ENV_FIELD}"
  }
}

How to use with django/drf

  • add new path to main project urls
from django.urls import path, include

urlpatterns = [
    # another paths
    path('', include('endmapper.urls'))
]

WARNING: all paths what you want add to endmapper must have "name"

How to use with fastAPI

from fastapi import FastAPI
from endmapper.mappers.fastapi_mapper import connect_app

from lib_1 import  some_router_1
from lib_2 import  some_router_2

app = FastAPI()

app.include_router(some_router_1)
app.include_router(some_router_2)

connect_app(app)

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

endmapper-0.4.7.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

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

endmapper-0.4.7-py3-none-any.whl (5.7 kB view details)

Uploaded Python 3

File details

Details for the file endmapper-0.4.7.tar.gz.

File metadata

  • Download URL: endmapper-0.4.7.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.2

File hashes

Hashes for endmapper-0.4.7.tar.gz
Algorithm Hash digest
SHA256 36c4a4ab2bc1db66f4a0d19b68bb81c31079f64920758e65255638ea4f42d219
MD5 89d33ad3f961c764d210d40e70a580af
BLAKE2b-256 386d71ee39df82aa7b6e42d7643b76cf54e39ba7b9e9527d178c5a049921be45

See more details on using hashes here.

File details

Details for the file endmapper-0.4.7-py3-none-any.whl.

File metadata

  • Download URL: endmapper-0.4.7-py3-none-any.whl
  • Upload date:
  • Size: 5.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.2

File hashes

Hashes for endmapper-0.4.7-py3-none-any.whl
Algorithm Hash digest
SHA256 e62a1369f389c66df87121266d1e66511c477a6c106b35088ca2f666b1da5841
MD5 5aed11a5d509bd27be7abc723b1057c1
BLAKE2b-256 8d37037e36622f5754582248a3a6ac38470f2918f371576648d4154c12e76560

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