Skip to main content

Camerge

PyPi version PyPI license PyPI pyversions

A simple library for merging multiple calendars into one. It also allows anonymization of the events, so nobody will be able to see the summary of the event.

What this solves: You have multiple calendars, and you want to share availability in ical format with some other people. This tool takes your private calendars (in ical format), merges them, optionally anonymize them and creates new ical calendar with the correct availability data.

This project is a minimal library but can be very easily used as an API for example:

import datetime
from fastapi import FastAPI, Response
from camerge import merge_calendars

app = FastAPI()


@app.get("/")
async def calendar():
    """
    This method generates ical data for any calendar app.
    """
    ical = merge_calendars(
        calendar_name='My Availability',
        calendar_domain='my.calendar.example.com',
        calendar_data=[
            # take this google ical stream and anonymize events (no event names shown)
            ("https://calendar.google.com/calendar/ical/me@me.com/private-x/basic.ics", True),
            # take this event stream and do not anonymize event summary
            ("https://p30-caldav.icloud.com/published/2/xxx", False),
        ],
        # take event availability from these email addresses, these should be your own
        # email addresses associated with the calendar accounts
        known_emails=[
            'me@example.com', 'otherme@example.com'
        ],
        # do not include events that are older than this
        skip_events_before=datetime.date(2021, 1, 1)
    )
    return Response(content=ical, media_type='text/calendar')

Dependencies

This project is based on icalendar.

Metadata

Release files for camerge 0.0.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for camerge 0.0.3
File Size Uploaded Provenance
camerge-0.0.3.tar.gz 8.1 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for camerge 0.0.3
File Interpreter ABI Platform
camerge-0.0.3-py3-none-any.whl Python 3 none any Details

Total release size: 14.2 kB

Release files / camerge-0.0.3.tar.gz

Download URL camerge-0.0.3.tar.gz
Size 8.1 kB
Tags Source
SHA-256 checksum
How to use checksums
008b723f6b1d1dad848b7ea756ca787bafd74187ca52086dd704b2318b61a3fa
BLAKE2b-256 checksum
How to use checksums
aa72ad3e053ce60592337cdf36791fcadbaae2d7686120cc211925b59900d740
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / camerge-0.0.3-py3-none-any.whl

Download URL camerge-0.0.3-py3-none-any.whl
Size 6.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0b8e8b70ff0d752a6a004fc02f8c7ccf7492cd0fdd9250b9808ff3707ac52dd5
BLAKE2b-256 checksum
How to use checksums
2b167d209946955802a4e25e05f85d99ce9ffd8ab304a16f2cefd8f7021e37ed
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Security for camerge 0.0.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page