Git Product home page Git Product logo

attestation-list-api's Introduction

DAO Attestations API

A DAOstar Project

The DAO Attestations API is a Flask-based web service designed to fetch and serve attestation data from the Optimism network's GraphQL endpoint. It allows clients to retrieve structured attestation data for a given attester address via a clean and simple REST API.

Features

  • Fetch attestation data using an attester's Ethereum address.
  • Structure and serve attestation data in a JSON format.
  • Handle requests to a GraphQL API to fetch raw attestation data.

Installation

To set up the DAO Attestations API on your local machine, follow these steps:

Prerequisites

  • Python 3.6 or later
  • pip (Python package manager)

Steps

  1. Clone the repository

    git clone https://github.com/metagov/Attestation-List-API
    cd Attestation-List-API
  2. Set up a virtual environment (optional but recommended)

    python -m venv venv
    source venv/bin/activate  # On Windows use `venv\Scripts\activate`
  3. Install dependencies

    pip install -r requirements.txt
  4. Run the application

    python main.py

    The API will be accessible at http://127.0.0.1:5000/.

Usage

Endpoints

  • Get Attestations for an Attester Address

    Request:

    GET /attestations/<attester_address>

    Response:

    • 200 OK - Returns structured attestation data for the specified attester address.
    • 400 Bad Request - If the attester address is not provided or invalid.
    • 500 Internal Server Error - If there was an error processing the request.
  • Home

    Request:

    GET /

    Response:

    • 200 OK - Returns a welcome message.

Examples

  • Fetching Attestations

    curl http://127.0.0.1:5000/attestations/0x88e50e06efB2B748E2B9670d2a66682371673888

Development

To contribute to the development of the DAO Attestations API, you can start by checking out our issue tracker or feature requests. Ensure to follow the project's code style and contribute guidelines.

Support

For support, please open an issue in the GitHub repository or contact Rashmi-278.

License

This project is licensed under the MIT License.

attestation-list-api's People

Contributors

rashmi-278 avatar

Watchers

Eugene Leventhal avatar Joshua Tan avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.