Skip to main content

hwpapi

PyPI Python License Docs Status

한글(HWP) 자동화를 위한 Pythonic 라이브러리. hwpapi.App 슬림 퍼사드 + app.doc.* 컬렉션 + hwpapi.low.* escape hatch 의 이중 레이어 API.

📖 전체 문서는 JunDamin.github.io/hwpapi — 설치 · 5분 투어 · Guide · Recipes · API Reference · v1 → v2 마이그레이션.


Requirements

  • Windows + 한컴 오피스 설치
  • Python 3.9+
  • pywin32

Install

pip install hwpapi

5분 투어

from hwpapi import App

app = App()                                   # HWP 연결
app.open("report.hwp")

# 컬렉션 — dict-like + iterable + filterable
app.doc.fields["name"] = "홍길동"
app.doc.bookmarks.add("ch1")
for tbl in app.doc.tables:
    print(tbl.caption, tbl.rows, "×", tbl.cols)

# 문단/런
for para in app.doc.paragraphs:
    print(para.style, "|", para.text[:40])

# Escape hatch — 저수준 actions / parametersets / engine
from hwpapi.low import actions, parametersets
char = parametersets.CharShape(app.actions.CharShape.pset)
char.bold = True
actions.CharShape(app).execute(char)

app.save()

더 많은 예제는 Recipes 를 참고하세요.


v1 → v2 변경점

v2 는 public API break 를 허용한 클린컷 릴리즈입니다.

v1.x v2.0
from hwpapi.core import App from hwpapi import App
app.fields[...] app.doc.fields[...]
app.bookmarks, app.images, ... app.doc.bookmarks, app.doc.images, ...
app.charshape = {...} with hwpapi.context.charshape_scope(app, bold=True): ...
app.preset.*, app.template.* (Phase-out — Recipes 페이지에서 레시피 형태로 재공급)
hwpapi.parametersets hwpapi.low.parametersets

전체 매핑 80+ 항목: Migration Guide

v1.x 에 머무르려면 pip install "hwpapi<2" 또는 git checkout v1.x.


기여

License

MIT

Metadata

Release files for hwpapi 3.0.0

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

Source distribution (sdist)

Source distribution for hwpapi 3.0.0
File Size Uploaded Provenance
hwpapi-3.0.0.tar.gz 206.6 kB With provenance Details

Built distribution (wheel)

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

Total release size: 416.8 kB

Release files / hwpapi-3.0.0.tar.gz

Download URL hwpapi-3.0.0.tar.gz
Size 206.6 kB
Tags Source
SHA-256 checksum
How to use checksums
654ea61ccc4e1f75118328a29cca54a57e531837c206d37a9da2948c847dc7a6
BLAKE2b-256 checksum
How to use checksums
816ec350e4800c725f8ffd32975c58fca324a9a15ca7d1217306a7f8fe8dd6fe
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 29, 2026.

Transparency log

Release files / hwpapi-3.0.0-py3-none-any.whl

Download URL hwpapi-3.0.0-py3-none-any.whl
Size 210.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d78964d643274fff6a91837116aaeffebd96852e00892b226ef542ecbfa348f6
BLAKE2b-256 checksum
How to use checksums
04ec0fd5f5db430640917c16f96f918320796188fcd7205b460cd45fe1f48200
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 29, 2026.

Transparency log

Security for hwpapi 3.0.0

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.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for hwpapi-3.0.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 29, 2026.

Transparency log

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.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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