Saravanan666/pypi-org huggingface dataset:
Package: api-clone
Project descriptionThis is a utility project that helps you download files attached to an api response and save them locally. It also includes method for downloading network images to your local storage.Theapi_server.api_downloadermanages all downloads for images linked with any json response.Supported Input TypesTheapi-clonesupports both json and normal python dictionaries for scraping api response. For downloading urls from url, a string would be requiredInstallationThe installation is simple:pip install api-cloneUsageTo download a single image from a urlfrom api_clone.api_downloader import saveImage

saveImage(image_url='url_of_image', folder_name='name of folder to save the image')To save all images from a json response locally on your devicefrom api_clone.api_downloader import ApiDownloader

downloader = ApiDownloader(your_json_response_here)
downloader.downloadAllImages(folder_name='name of folder for saving images')Save all images under a specifickeyin the json file. This method saves images with values having the same key as you specified.from api_clone.api_downloader import ApiDownloader

downloader = ApiDownloader('json_response')
downloader.downloadImagesAtKey(key_name='name of image key', folder_name='folder name')FieldsfieldtypeDefaultdescriptionmapdictNonejson responsefolder_namestrimagesname of the folder where your images are savedimage_formatImageFormatImageFormat.jpgformat to save the image ie.png,jpg,jpegFeaturesDownload all network images referenced from a json fileRename image json with names of local images on the pc
Package: api-cloudvps-py
INSTALLING$pipinstallapi-cloudvps-py# or use source code package, after extract$pythonsetup.pyinstallHow to obtain tokenIf you want to work with reg.ru cloudvps api clientorder free serviceMore info about reg.ru kvm cloudhttps://www.reg.ru/vps/cloudUSAGE# import>>>fromcloudvpsimportApi>>>api=Api('3f7c0a3d*****356b45d59f71a')# or>>>importcloudvps>>>api=cloudvps.Api('3f7c0a3d*****356b45d59f71a')>>>common=api.common>>>print(common.sizes()){'sizes':[{'disk':10,'id':5,'memory':512,'name':'Cloud-1','price':'0.30','price_month':199,'slug':'cloud-1','vcpus':1,'weight':10},{'disk':20,'id':1,'memory':1024,'name':'Cloud-2','price':'0.67','price_month':449,'slug':'cloud-2','vcpus':2,'weight':20},{'disk':40,'id':3,'memory':2048,'name':'Cloud-3','price':'1.34','price_month':899,'slug':'cloud-3','vcpus':2,'weight':30},{'disk':60,'id':7,'memory':4096,'name':'Cloud-4','price':'2.66','price_month':1790,'slug':'cloud-4','vcpus':2,'weight':40},{'disk':60,'id':9,'memory':6144,'name':'Cloud-5','price':'3.71','price_month':2490,'slug':'cloud-5','vcpus':2,'weight':50},{'disk':80,'id':11,'memory':8192,'name':'Cloud-6','price':'4.75','price_month':3190,'slug':'cloud-6','vcpus':4,'weight':60}]}LICENSEThe MIT License (MIT) 2018, Anton Grudin.
Package: apico
apicoThe easy way to monitor changes in RESTful APIs.Installation$ pip install apicoExample usagefromapicoimportMonitor,Responsemonitor=Monitor(url='https://api.github.com/users/itsmewulf',rate=10.0,headers={'Authorization':'GITHUB_TOKEN'})@monitor.listener()defon_change(old,new):print('Something changed!')@monitor.listener('no_change')defnothing_changed():print('Nothing changed!')@monitor.listener()defon_request():print('This is called before every request.')Some referenceEventsThe events supported by theMonitor.listenerdecorator are:changerequestno_changeAs you can see in the example, listeners can be registered by passing the event name straight to the decorator (monitor.listener('change')) or inferred from the function name starting withon_:@monitor.listener()defon_change(...):Monitor argumentsThe monitor accepts a boatload of arguments, mainly ones that are then passed down torequests.Session.request(), so, for a detailed insight follow the hyperlink or read the docstring.ReturnsThe responses returned by apico are actually instances ofrequests.ResponseRateThe rate at which the Monitor sends requests is controlled via therateparameter, which is either an integer, or a float -33is a request every 33 seconds,0.5is 2 requests every second.Reporting IssuesIf you find any error/bug/mistake with the package or in the code feel free to create an issue and report
ithere.Fix/Edit ContentIf you wish to contribute to this package, fork the repository, make your changes and then simply create a Pull Request!
Package: apiComs
winter-api-commonsThis is a package to stremaline api method callsThis module containes the major reusable functions which can be imported and accessed directly which will reduce the time and code redundancy.Installationpip install apiComSample code:import apiCom
url = "https://api.car.com/teslar/model1"
header = {}
resp = apiCom.get_api(url, header)
print(resp.json())
Package: api-console-solver
Material de apoioO primeiro passo Ã© ter o cÃ³digo de sua biblioteca separado em uma pastameu_pacote/ # Pasta do projetocodigos_da_biblioteca/ # DiretÃ³rio onde deve ficar os cÃ³digos de sua bibliotecaLICENCE # Um arquivo com a licenÃ§a da sua libREADME.MD# Uma descriÃ§Ã£o do projetosetup.py# CÃ³digo Python responsÃ¡vel pelo empacotamentoAdicione uma licenÃ§aThe MIT License (MIT)

Copyright (c) [year] [fullname]

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.Adicione um readme# Sua descriÃ§Ã£o aquiInstale a lib setuptoolspip install setuptoolsCrie osetup.pyfrom setuptools import setup

with open("README.md", "r") as arq:
    readme = arq.read()

setup(name='wrapper-panda-video',
    version='0.0.1',
    license='MIT License',
    author='Caio Sampaio',
    long_description=readme,
    long_description_content_type="text/markdown",
    author_email='caio@pythonando.com.br',
    keywords='panda video',
    description=u'Wrapper nÃ£o oficial do Panda Video',
    packages=['panda_video'],
    install_requires=['requests'],)Execute o comandopython setup.py sdistInstale o twine para fazer o upload para o pypipip install twineCrie uma conta no pypiExecute o comando para criar um repositÃ³rio de testetwine upload --repository-url https://test.pypi.org/legacy/ dist/*Ou para criar um repositÃ³rio oficial:twine upload dist/*
Package: apiconsumer
Following the same philosophy of Requests module (REST) ApiConsumer is here to make your life easier.Are you lazy enough to configure authentication for every single request? How about handling errors? Wouldn’t it be
great if all that could be done in 2 lines?How to useBehold the power of ApiConsumer:>>>fromapiconsumerimportApiConsumer>>>my_api=ApiConsumer(url='https://myapi.com',extra_headers={'Authorization':'JWT mytoken'})>>>users=my_api.get_users()Making POST request is also easy:>>>new_user=my_api.post_users(data={'email':'someguy@something.com','password':'correct-horse-battery-staple'})How to install$pipinstallapiconsumerContributeBe our guest. We’d like to see your awesome ideas. Just fork the repo, create a branch and create pull request.
Package: apicore
Set of core libraries usefull for building REST API and Microservices based on Flask.The code is open source, release under MIT and written in Python 3.pipinstallapicoreFeaturesCross-origin resource sharing (CORS) readyData caching with redis server or in-memoryConfiguration file loaderA simple LoggerRaise exception conform to HTTP status codesAuthorization using JSON Web Token(JWT) issued from an OpenID Connect provider.LinksDocumentationSource codeCompany
Package: apicPython
All the codes are in object oriented style.Each of them does a small configuration on APIC – to create a MO. For example, createTenant.py would create a tenant.Programmer can simply write their customized script by inheriting the class createMo in “createMo.py”.#Scripts descriptions:createMo.py: the basic class/module. It also contains useful functions that help programmers for writing their customized scripts.The others are generic scripts. Each of them does a small configuration. For example, createContract.py would create a contract.#Usage:All the codes support three different input methods: wizard, yaml and cli.1. wizard: configure a mo by following a wizard. Usage:
<br>python createFilter.py wizard
<br>To get the help info: python createFilter.py wizard –h2. yaml: configure a mo with a config file (yaml format). Usage:
<br>python createFilter.py yaml createFilter.yaml
<br>To get the help info: python createFilter.py yaml –h3. cli: configure a mo based on you python arguments.  It contains key arguments and optional arguments. Flags are used in order to call the optional arguments. Usage:
<br>python createFilter.py cli <ip-address> <user-name> <password> <tenant> <filter> [–e ip –i tcp]
<br>To get the help info: python createFilter.py cli –h#Delete a mo:Using -d flag. Example if you want to delete a filter, you can call createFilter.py with a -d flag. The delete method is supported in all three input methods. For example:<br>python createFilter -d yaml
<br>python createFilter -d wizard
<br>python createFilter -d cli <ip-address> <user-name> <password> <tenant> <filter>
Package: apic_python
All the codes are in object oriented style.
They are functional codes and at the some time they are sample codes. Programmer can simply write their customized script by inheriting the class createMo in “createMo.py”.#How to use:All the codes support three different input methods: wizard, yaml and cli.1. wizard: configure a mo by following a wizard. Usage:
<br>python createFilter.py wizard
<br>To get the help info: python createFilter.py wizard –h2. yaml: configure a mo with a config file (yaml format). Usage:
<br>python createFilter.py yaml createFilter.yaml
<br>To get the help info: python createFilter.py yaml –h3. cli: configure a mo based on you python arguments.  It contains key arguments and optional arguments. Flags are used in order to call the optional arguments. Usage:
<br>python createFilter.py cli 172.31.216.100 admin ins3965! tenantA filterA –e ip –i tcp
<br>To get the help info: python createFilter.py cli –h#What are those codes:createMo.py: the basic class/module. It also contains useful functions that help programmers for writing their customized scripts.The other scripts are functional scripts. Each of them does a small work. For example, createTenant.py only creates an “empty” tenant without any other setup.#How to delete a mo:Using -d flag. Example if you want to delete a filter, you can call createFilter.py with a -d flag. The delete method is supported in all three input methods. For example:<br>python createFilter -d yaml
<br>python createFilter -d wizard
<br>python createFilter -d cli 172.31.216.100 admin ins3965! tenantA filterA
Package: apicrafter
# apicrafterapicrafter helps people create simple HTTP APIs easily.## Requirementsapicrafter requires Python 3## InstallationTo install the latest stable version with pip```bash$ pip install apicrafter```## Quick startTo start creating an API, all you need is a path, a function, and a method```pythonimport apicrafterdef root_request_handler(request):request.respond("<b>Hello, world!</b>")#Starts ApiServer on all interfaces on port 8080my_server = apicrafter.ApiServer('all', 8080)my_server.add_handler('/', root_request_handler, 'GET')my_server.start()```Then, just navigate to http://localhost:8080 on the web browser of your choice!
Package: apicrud
apicrudWhat is thisSkip the kubernetes / python / React.js learning curve and put your ideas in production!TheAPIcrudframework makes it easier to get started on full-stack development of REST-based services, ranging from a simple CLI wrapper for queries of local APIs to full web-scale consumer-facing applications running on kubernetes.The essential components of a modern full-stack application include a back-end API server, a front-end UI server, a database, a memory-cache and a background worker for performing actions such as emailing, photo uploading or report generation. The challenge of setting up CI testing and microservice deployment is usually daunting; this repo addresses all of those issues by providing a fully-working example you can set up and start modifying in minutes. No prior experience is required.This is the API back-end and worker, with anexampleapplication.UsageSee thegetting startedpage, or navigate toRead the Docs.BackgroundThe rise of Docker and Kubernetes starting around 2017 made it possible to set up these production-grade services directly on the laptop of any developer. Only recently have the tools been easier to configure and set up. This framework provides working example code you can use to get started creating your own secure, web-scale services.Implementation/design includes these technologies:babel,celery,CloudFront and S3,docker,flask,kubernetes,MapQuest geocoding,mapbox,MariaDB,OAuth 2.0,python 3,OpenAPI,PyOTP,RabbitMQ,react.js,react-admin,redis,sqlalchemy,uWSGI.ContributionsYour pull-requests and bug-reports are welcome here. SeeCONTRIBUTING.md.LicenseSoftware copyright © 2021 by Richard Braun •Apache 2.0license
Package: apicrypto
cryptoapiМодуль для работы с Crypto API |Официальное приложениеУстановка и импортДля установки необходимо прописать в консоль (cmd) следующую команду:pip install apicryptoДля импорта модуля в проект использовать:fromcryptoapiimportCryptoAPIИспользованиеПеред началом необходимо создать экземпляр класса CryptoAPI, который принимает 2 аргумента:АргументТипОписаниеuser_idintID Пользователя VK, который получил токенtokenstrТокен, полученный в самом приложении CryptofromcryptoapiimportCryptoAPIcrypto=CryptoAPI(user_id=ваш_ID,token="Ваш_Токен")getUserCoins()Возвращает баланс указанного пользователя.АргументТипОписаниеuser_idintID Пользователя VK, баланс которого необходимо получитьЕсли не указывать user_id, то подставится ID из созданного экземпляраcrypto.getUserCoins(user_id=498475943)>>>1139888getTransfers()Возвращает список всех переводовcrypto.getTransfers()>>>[{'name':'Алекса...}]transfer()Отправляет перевод.АргументТипОписаниеtoIdintID пользователя, кому отправляем переводamountintСумма переводаcrypto.transfer(toId=498475943,amount=100)>>>{"response":{"recipient_id":498475943,"amount":100}}connectServer()Настраивает отправку callback уведомлений на Ваш сервер / сайт.АргументТипОписаниеurlstrАдрес сервера / сайта, куда буду приходить уведомленияcrypto.connectServer(url="https://mysite.mydomain")>>>{"response":{"url":"https://mysite.mydomain","user_id":498475943}}Обратите внимание, что ссылка обязательно должна начинаться с https:// или http://После получения перевода, callback возвращает JSON Объект события следующего вида:{"event":"new_transfer","object":{"sender_id":498475943,"amount":1000,"create_date":1687423373784,"secretKey":"18e0f585616e1ece62316072a45f64e4"}}listen()Запускает встроенный прослушиватель переводов. При получении нового перевода возвращает JSON.АргументТипОписаниеintervalintЗадает интервал обновления переводов в секундах (По умолчанию: 1)forobjectincrypto.listen(interval=0.1):print(object)>>>{"name":"Иван Шаповалов","avatar":"https://sun34-2.userapi.com/impg/0MjzdwFu6WRSYod_65kU0BjdVpNcqWyxXmr76g/ZlbXvz3CTSs.jpg?size=720x720&quality=95&sign=ae29a8d9bacfab080534f3f2cb964963&type=album","sender_id":498475943,"recipient_id":487364833,"create_date":1687416286823,"amount":1000}md5()Генерирует secretKey для проверки callback переводов на честность (Подробней -https://vk.com/@crypto_play-api?anchor=connectserver)Имеется два варианта передачи параметров для генерации secretKeyПервый вариантАргументТипОписаниеcreate_dateintДата перевода в UNIXsender_idintID Отправителяcrypto.md5(create_data=1689398602,sender_id=498475943)>>>'876104e5cee8669f1b89448282215da5'Второй вариантАргументТипОписаниеjsondict / jsonJSON полученного переводаcrypto.md5(json={'event':'new_transfer','object':{'sender_id':1,'amount':10000,'create_date':1689408602,'secretKey':'1287a00828e7e44ea83b7d90caf938a1'}})>>>'1287a00828e7e44ea83b7d90caf938a1'
Package: apicurioregistryclient
Apicurio Registry is a datastore for standard event schemas and API designs. Apicurio Registry enables developers to manage and share the structure of their data using a REST interface. For example, client applications can dynamically push or pull the latest updates to or from the registry without needing to redeploy. Apicurio Registry also enables developers to create rules that govern how registry content can evolve over time. For example, this includes rules for content validation and version compatibility.  The Apicurio Registry REST API enables client applications to manage the artifacts in the registry. This API provides create, read, update, and delete operations for schema and API artifacts, rules, versions, and metadata.   The supported artifact types include: - Apache Avro schema - AsyncAPI specification - Google protocol buffers - GraphQL schema - JSON Schema - Kafka Connect schema - OpenAPI specification - Web Services Description Language - XML Schema DefinitionImportant: The Apicurio Registry REST API is available from &#x60;https://MY-REGISTRY-URL/apis/registry/v2&#x60; by default. Therefore you must prefix all API operation paths with &#x60;../apis/registry/v2&#x60; in this case. For example: &#x60;../apis/registry/v2/ids/globalIds/{globalId}&#x60;.   # noqa: E501
Package: apidag
apidagA Python library using asyncio and aiohttp to build declarative API call flows. Designed for minimal repetition of definitions, modularity, and reusability, flowlib allows chaining of APIs, alongside formatting functions, in a directed acyclic graph. API definitions are defined as nodes of a graph, with their key elements (such as base URL, input and output parameters, and error handling) as attributes:# Define the APIs as nodesxkcd_node=apidag.APINode(id="xkcd_api",base_url="https://xkcd.com/{id}/info.0.json",input_params={"id":apidag.URLParam("id")},output_params={"title":"$.safe_title"},error_handlers={404:lambdainput:{"title":["No title found"]}},)dictionary_node=apidag.APINode(id="dictionary_api",base_url="https://api.dictionaryapi.dev/api/v2/entries/en/{word}",input_params={"word":apidag.URLParam("word")},output_params={"definition":"$..meanings[*].definitions[*].definition"},error_handlers={404:lambdainput:{"definition":["No definition found"]}})The connections between APIs are defined as edges of the graph:# Define edgesdefxkcd_to_dictionary(outputs):title=outputs.get("title")[0]words=title.split()first_word=words[0].lower()ifwordselse""return{"word":first_word}edge=apidag.Edge(source="xkcd_api",target="dictionary_api",linkage_function=xkcd_to_dictionary)# Define the flowflow=apidag.APIFlow(nodes=[xkcd_node,dictionary_node],edges=[edge])Finally, with the flow defined, it's relatively straightforward to define a getter, the initial inputs, and a callback that does final processing once results are all gathered:# Define callbackdefcallback(results):comic_data=results.get("xkcd_api",{})dictionary_data=results.get("dictionary_api",{})comic_title=comic_data['output'].get('title',["Unknown Title"])[0]first_word=dictionary_data['input'].get('word',"Unknown Word")definitions=dictionary_data['output'].get('definition',[])ifnotisinstance(definitions,list):definitions=[definitions]iflen(definitions)==0:print(f"Comic #{comic_data['input']['id']}titled '{comic_title}' has its first word '{first_word}' undefined.")else:print(f"Comic #{comic_data['input']['id']}titled '{comic_title}' has its first word '{first_word}' defined as:")fordefinitionindefinitions:print("\t"+definition)# Initialize the gettergetter=apidag.Getter(max_retries=3,workers=10)# List of comic IDs to fetch in parallelcomic_ids=range(2630,2650)# Define a main coroutineasyncdefmain():tasks=[getter.run_flow(flow,{"id":str(comic_id)},callback)forcomic_idincomic_ids]awaitasyncio.gather(*tasks)# Execute the main coroutineasyncio.run(main())This is all essentially identical to what's in the demo.pyfile, and note that there's no need for this flow to be linear! At runtime, the library builds the DAG of the nodes and will fail if there are any cyclic dependencies. When possible, it will try to do HTTP requests in parallel (note theworkersargument to the getter) usingasyncioandaiohttpfor concurrency. This is still in its infancy and subject to change, but please let me know if this is compelling to you!
Package: apidatawho
Explore a world of health data (THE GLOBAL HEALTH OBSERVATORY) python Library for world health organization APIThis is a python package having multiple utilities.Github-flavored Markdown[Source : https://www.who.int/data/gho/info/gho-odata-api]
1.whoApi.getDimension() : Retrieving the list of available dimensions
2.whoApi.DimensionValues() : Retrieving a list of available values for a specific dimension
3.whoApi.IndicatorValue() : Retrieving the indicators list
4.whoApi.IndFilterlike(IndicatorNameVal) : To select only the indicators which contain a specific text.Retrieving the indicators list
5.whoApi.IndFilterSpec(Tindicator) : To select only the indicators that have a specific title,Retrieving the indicators list
6.whoApi.IndData(IndCode) : Specify an indicator to download by specifying the indicator code.
This will return all associated data for that specific indicator.
Retrieving indicator data
7.whoApi.IndAllData():Retrieving All Ind data in pandas dataframe,
Warning : Please set our context memory size before calling this function#Data Returns in three format:
JSON,DF(DataFrame),XML. Default Format is : JSON
Package: apidb
apidbAutogenerate API based on DB structure directly from Python using ORMInstallationUse the package managerpipto install apidb.pipinstallapidbUsagefromfastapiimportFastAPIimportapidb.apidb_coreasadimportuvicorndescription="""This is your API"""app=FastAPI(title="Example API",description=description,version="1.0.0",)db_api_dict={'workspaces':'read','nodes':['read','create','update','delete']}column_names=["workspace_name"]ad.initialize_fastapi(app,db_api_dict,column_names,mysql)@app.get("/api/v1/custom_workspaces")defget_workspaces():"""Returns all workspaces"""return{"workspaces":[]}defrun_api():uvicorn.run(app,host="0.0.0.0",port=8000)if__name__=="__main__":run_api()Current scopeAims: Easy generation of API in Fastapi + Flask based on structure in DB (current dialects: MySQL, PostgreSQL, SQL Server, Mongo) or on series of predefined functionsDone: Flask and FastAPI simple exampleTodo: GeneralizationContributingPull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.LicenseMIT