Metadata-Version: 2.3
Name: fedkit
Version: 0.1.0
Summary: A reusable app to implement fediverse functionality.
Author: Andreas Neumeier
Author-email: Andreas Neumeier <andreas@neumeier.org>
License: MIT License
         
         Copyright (c) 2025 deltabps
         
         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.
Classifier: Framework :: Django
Classifier: Programming Language :: Python :: 3
Requires-Dist: celery[redis]
Requires-Dist: django>=5.2
Requires-Dist: djangorestframework
Requires-Dist: pillow
Requires-Dist: pyld
Requires-Dist: requests
Requires-Python: >=3.11
Project-URL: Bug Tracker, https://codeberg.org/deltabps/fedkit/issues
Project-URL: Changelog, https://codeberg.org/deltabps/fedkit/issues
Project-URL: Documentation, https://docs.pramari.de
Project-URL: Homepage, https://pramari.de/@fedkit
Project-URL: Repository, https://codeberg.org/deltabps/fedkit
Description-Content-Type: text/markdown

# fedkit

# fedkit: ActivityPub & ActivityStreams for Python & Django

**fedkit** is a Python library built to enable easy integration of the **ActivityStreams** and **ActivityPub** federation protocols into Python-built websites, with a particular focus on the **Django** framework.

It allows your application to participate in the Fediverse, enabling seamless communication with other federated services like Mastodon, Pleroma, and PeerTube.

-----

## ✨ (Planned) Features

  - [ ] **ActivityStreams Object Handling:** Simple and declarative Python classes for creating, validating, and serializing **ActivityStreams** objects.
  - [ ] **ActivityPub Protocol Support:** Tools for handling **Inboxes**, **Outboxes**, and remote actor discovery (WebFinger).
  - [ ] **Django Integration:** Built-in utilities, database models, and view helpers to quickly add federation capabilities to your existing Django project.
  * [ ] **Decoupled Design:** Core federation logic can be used in any Python web framework (Flask, FastAPI, etc.).

-----

## 🚀 Installation

You can install `fedkit` directly using pip:

```bash
pip install fedkit
```

### Django Setup

1.  **Add to `INSTALLED_APPS`**:
    To integrate `fedkit` into your Django project, add it to your `settings.py`:

    ```python
    # settings.py

    INSTALLED_APPS = [
        # ... your other apps
        'fedkit',
        # ...
    ]
    ```

2.  **Include URLs**:
    Add the `fedkit` URLs to your project's `urls.py` to handle standard ActivityPub routes (like actor inboxes/outboxes):

    ```python
    # urls.py

    from django.urls import path, include

    urlpatterns = [
        # ... your other URLs
        path('@', include('fedkit.urls')),
    ]
    ```

3.  **Run Migrations**:
    Apply the necessary database migrations:

    ```bash
    python manage.py migrate
    ```

-----

## ⚙️ Basic Usage

### 1\. Defining a Federating Model

You can extend the built-in `fedkit` Actor and Object models to make your application's entities addressable in the Fediverse.

```python

```

### 2\. Creating an Activity

Use the dedicated utilities to create and sign an Activity, then deliver it to an Outbox.

```python

```

-----

## 📖 Documentation & Examples

For detailed instructions on configuring federation settings, customizing views, handling **Inboxes**, and implementing full server-to-server communication, please refer to the official documentation (coming soon).

-----

## 🤝 Contributing

**fedkit** is an open-source project and contributions are highly welcome\!

If you'd like to contribute, please check out the repository on Codeberg, fork the project, and submit a pull request with your suggested changes. You can also report issues or suggest features via the issue tracker.

-----

## ⚖️ License

This project is licensed under the **[LICENSE\_HERE]** License.

Please see the `LICENSE` file in the repository for more details.