Skip to main content
Hero Light

Welcome to Resource Service

Resource Service is a FastAPI-based microservice designed for managing sustainability indicators through AI-generated data wrappers. It provides a comprehensive solution for collecting, processing, and distributing sustainability data from multiple sources including APIs, CSV files, and Excel spreadsheets.

Quick Start

Get up and running in under 5 minutes with Docker Compose

Installation Guide

Detailed setup instructions for development and production environments

API Reference

Complete API documentation for all available endpoints

Core Concepts

Understand resources, wrappers, and data collection workflows

Key Features

Generate intelligent data collection wrappers using Google’s Gemini AI. The service automatically creates Python code to fetch and process sustainability indicator data from various sources.
Support for multiple data sources:
  • API Integration: Connect to REST APIs with flexible authentication (Bearer, API Key, Basic Auth)
  • CSV Files: Process uploaded CSV files with automatic validation
  • Excel Spreadsheets: Handle XLSX files with preview and validation
Wrappers operate in two phases:
  • Historical Phase: Collect all historical data from the source
  • Continuous Phase: Monitor for new data points in real-time
Automatic checkpointing ensures resumable execution after service restarts.
Monitor wrapper execution with detailed health status, logs, and metrics:
  • Process status tracking
  • Execution logs with timestamps
  • Data points count and timing information
  • High/low water marks for data synchronization
Built on RabbitMQ for reliable message passing:
  • Asynchronous wrapper generation
  • Data point streaming to consumers
  • Resource lifecycle events
  • Scalable and decoupled architecture

Architecture Overview

The Resource Service is built with modern microservice patterns:

FastAPI

High-performance async API framework with automatic OpenAPI documentation

MongoDB

Flexible document storage for resources, wrappers, and file metadata

RabbitMQ

Message broker for async operations and event streaming

Use Cases

1

Environmental Data Collection

Collect air quality, water quality, and climate data from government APIs and research databases.
2

Social Indicators

Aggregate social sustainability metrics from CSV reports and Excel spreadsheets provided by organizations.
3

Economic Metrics

Monitor economic indicators through continuous API polling with automatic data validation.
4

Governance Tracking

Track governance and policy indicators with historical analysis and real-time updates.

Technology Stack

# Web Framework
fastapi==0.116.1
uvicorn==0.35.0

# Database
motor==3.7.1
pymongo==4.14.0

# Message Queue
aio-pika==9.5.7

# AI Integration
google-genai[aiohttp]>=0.3.0

# Data Processing
pandas>=2.0.0
openpyxl>=3.1.0

What’s Next?

Get Started Now

Follow the quickstart guide to launch your first wrapper

Read the Installation Guide

Learn about detailed setup options and configuration
Prerequisites: Docker and Docker Compose are required. You’ll also need a Google Gemini API key for AI-powered wrapper generation.

Build docs developers (and LLMs) love