Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

api-nichotined

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

api-nichotined

Simple lib for testing rest API

  • 0.1.13
  • PyPI
  • Socket score

Maintainers
1

API-NICHOTINED

A package that will help on creating session upon making rest API request.

Installation:

pip install api-nichotined

Sample usage:

import logging

from api_nichotined import Api, BigQuery


class TestApi(Api):
    def __init__(self):
        super().__init__("https://restcountries.com")

    def get_upload(self):
        return self.get(path="/v3.1/name/indonesia")

    @classmethod
    def init_bigquery(cls):
        bq = BigQuery()

        bq.authenticate_client_with_json_cred_path("cred.json")
        res = bq.get_rows_from(query="""SELECT * FROM `dummy` LIMIT 1000""")
        assert type(res[0].column_a) == str


if __name__ == '__main__':
    logging.basicConfig(level=logging.INFO, format="%(asctime)s - %(levelname)s - %(message)s")

    response = TestApi().get_upload()
    TestApi.init_bigquery()

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc