Skip to main content

Structured Workout Format (SWF) — a JSON format for describing structured endurance workouts.

Project description

Structured Workout Format (SWF)

SWF is a JSON format for describing structured endurance workouts. Define a workout once in SWF, then export to Garmin, Intervals.icu, or other platforms.

uv add structured-workout-format
from structured_workout_format import Workout, Step, Repeat, duration, power, to_garmin

workout = Workout(
    sport="cycling",
    content=[
        Repeat(count=5, content=[
            Step(volume=duration(240), intensity=power(250)),
            Step(effort="rest", volume=duration(120)),
        ]),
    ],
)

print(to_garmin(workout))

Full documentation, specification, and examples at structuredworkoutformat.dev.

Source code and conformance suite on GitHub.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

structured_workout_format-0.5.0.tar.gz (1.3 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

structured_workout_format-0.5.0-py3-none-any.whl (27.4 kB view details)

Uploaded Python 3

File details

Details for the file structured_workout_format-0.5.0.tar.gz.

File metadata

File hashes

Hashes for structured_workout_format-0.5.0.tar.gz
Algorithm Hash digest
SHA256 554e5181c95a8675d6cc2cf3cb90c8b6c17947f0edb9c4ff6f077b4b4f13e1e1
MD5 e7832c6b19d620b3480fa80bd445ae68
BLAKE2b-256 42a6c1131b444b47d0b3929cb809dded7c3808abc241cdde6f2361e98b19b0f1

See more details on using hashes here.

File details

Details for the file structured_workout_format-0.5.0-py3-none-any.whl.

File metadata

File hashes

Hashes for structured_workout_format-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cecc64b14af43ddfa6d593d09cc1d25f2475070aaf6319f4b1167a92e4de0d73
MD5 904553a72ec43dc153e68eb7404786ac
BLAKE2b-256 dc05ef0b55b067e0c9b99fa0e1d9b29acdcc3e036c6a7da41f717eeed2dc6d22

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page