Contributing to TESAIoT Developer Hub

We welcome contributions from the community! This guide will help you get started.

Ways to Contribute

  1. Report Bugs: Found an issue? Open a bug report
  2. Suggest Features: Have an idea? Open a feature request
  3. Add Examples: Create new examples for the community
  4. Improve Docs: Fix typos, clarify instructions, add tutorials
  5. Review PRs: Help review pull requests from other contributors

Code of Conduct

Please be respectful and constructive. We’re all here to learn and build great things.

Development Setup

Prerequisites

  • Git
  • Node.js 18+ (for JavaScript/TypeScript examples)
  • Python 3.10+ (for Python examples)
  • Docker (for testing containers)

Clone the Repository

1
2
git clone https://github.com/tesaiot/developer-hub.git
cd developer-hub

Testing Examples

Each example can be tested independently:

1
2
3
4
5
6
7
8
9
10
11
cd examples/<example-name>

# Python examples
python -m pytest tests/

# JavaScript examples
npm test

# Docker
docker build -t test-example .
docker run --rm test-example

Adding a New Example

1. Create Directory Structure

1
mkdir -p examples/my-example/{src,tests,docs}

2. Required Files

Every example must include:

File Description
README.md Setup instructions and usage
Dockerfile Container deployment
.env.example Configuration template
ARCHITECTURE.md Technical design (optional)

3. README Template

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# Example Name

Brief description of what this example does.

## Features

- Feature 1
- Feature 2

## Quick Start

### Prerequisites

- Required software

### Installation

\`\`\`bash
# Installation commands
\`\`\`

### Configuration

\`\`\`bash
cp .env.example .env
# Edit .env with your values
\`\`\`

### Running

\`\`\`bash
# Run commands
\`\`\`

## API Reference

Document any APIs exposed by the example.

## License

Apache 2.0 - See [LICENSE](../../LICENSE)

## Credits

Built with [TESAIoT Platform Examples](https://github.com/tesaiot/developer-hub)

4. Code Style

  • Python: Follow PEP 8, use type hints
  • JavaScript/TypeScript: Use ESLint + Prettier
  • Comments: Write clear, helpful comments
  • Tests: Include basic tests where applicable

5. Docker Requirements

1
2
3
4
5
6
# Multi-stage build preferred
FROM node:20-alpine AS builder
# ... build steps

FROM node:20-alpine AS production
# ... production setup

Pull Request Process

1. Fork and Branch

1
2
3
# Fork on GitHub, then:
git clone https://github.com/YOUR-USERNAME/developer-hub.git
git checkout -b feature/my-new-example

2. Make Changes

  • Write clear commit messages
  • Keep changes focused and atomic
  • Update documentation

3. Test Your Changes

1
2
3
4
5
6
7
# Test the example works
cd examples/my-example
./test.sh  # or equivalent

# Test Docker build
docker build -t test .
docker run --rm test

4. Submit PR

  • Fill out the PR template
  • Reference any related issues
  • Request review from maintainers

5. Review Process

  • Maintainers will review within 5 business days
  • Address feedback promptly
  • Once approved, PR will be merged

Documentation Contributions

Local Preview

1
2
3
4
cd docs
bundle install
bundle exec jekyll serve
# Open http://localhost:4000/developer-hub/

Writing Guidelines

  • Use clear, concise language
  • Include code examples
  • Add screenshots where helpful
  • Keep technical jargon to a minimum

Questions?

Thank you for contributing to TESAIoT Developer Hub! 🚀