This release is a pre-release and may not be stable for production use.
Nadeshiko SDK
Python SDK for the Nadeshiko API.
Install
pip install nadeshiko-sdk
Use the public SDK
The client sends your API key as Authorization: Bearer <apiKey>.
import os
from nadeshiko import Nadeshiko
from nadeshiko.api.search import search
from nadeshiko.models import Error, SearchRequest
client = Nadeshiko(
base_url=os.getenv("NADESHIKO_BASE_URL", "https://api.nadeshiko.co"),
token=os.getenv("NADESHIKO_API_KEY", "your-api-key"),
)
result = search.sync(
client=client,
body=SearchRequest(query="彼女"),
)
if isinstance(result, Error):
print(result.code, result.detail)
else:
for sentence in result.sentences:
print(sentence.segment_info.content_jp)
Error handling
Every response returns either a typed response object or an Error. The Error object follows the RFC 7807 Problem Details format, so you always get a machine-readable code and a human-readable detail.
import os
from nadeshiko import Nadeshiko
from nadeshiko.api.search import search
from nadeshiko.models import Error, SearchRequest
client = Nadeshiko(
base_url=os.getenv("NADESHIKO_BASE_URL", "https://api.nadeshiko.co"),
token=os.getenv("NADESHIKO_API_KEY", "your-api-key"),
)
result = search.sync(
client=client,
body=SearchRequest(query="食べる"),
)
if isinstance(result, Error):
match result.code:
# 400 — Bad Request
case "VALIDATION_FAILED":
print("Validation failed:", result.detail)
case "INVALID_JSON":
print("Malformed JSON body:", result.detail)
case "INVALID_REQUEST":
print("Invalid request:", result.detail)
# 401 — Unauthorized
case "AUTH_CREDENTIALS_REQUIRED":
print("Missing API key or session token")
case "AUTH_CREDENTIALS_INVALID":
print("API key is invalid")
case "AUTH_CREDENTIALS_EXPIRED":
print("Token has expired, re-authenticate")
case "EMAIL_NOT_VERIFIED":
print("Email verification required")
# 403 — Forbidden
case "ACCESS_DENIED":
print("Access denied")
case "INSUFFICIENT_PERMISSIONS":
print("API key lacks the required scope")
# 429 — Too Many Requests
case "RATE_LIMIT_EXCEEDED":
print("Rate limit hit, slow down")
case "QUOTA_EXCEEDED":
print("Monthly quota exhausted")
# 500 — Internal Server Error
case "INTERNAL_SERVER_EXCEPTION":
print("Server error, trace ID:", result.instance)
else:
for sentence in result.sentences:
print(sentence.segment_info.content_jp, "—", sentence.basic_info.name_anime_en)
See examples/examples.py for more usage patterns.
Metadata
Release files for nadeshiko-internal-sdk 1.5.1.dev1773237176
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| nadeshiko_internal_sdk-1.5.1.dev1773237176.tar.gz | 102.7 kB | With provenance | Details for nadeshiko_internal_sdk-1.5.1.dev1773237176.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| nadeshiko_internal_sdk-1.5.1.dev1773237176-py3-none-any.whl | Python 3 | none | any | Details for nadeshiko_internal_sdk-1.5.1.dev1773237176-py3-none-any.whl |
Total release size: 458.3 kB
Release files / nadeshiko_internal_sdk-1.5.1.dev1773237176.tar.gz
| Download URL | nadeshiko_internal_sdk-1.5.1.dev1773237176.tar.gz |
|---|---|
| Size | 102.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d732b8fbb7cedec567b2bf7ecd85cd760a5ccbff143aa75a063e72fffaa965d5
|
|
BLAKE2b-256 checksum How to use checksums |
2b2084759116787707b21261cfd873131a51a20345f04c9c31728186f4ccc912
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
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 Mar 11, 2026.
Transparency logRelease files / nadeshiko_internal_sdk-1.5.1.dev1773237176-py3-none-any.whl
| Download URL | nadeshiko_internal_sdk-1.5.1.dev1773237176-py3-none-any.whl |
|---|---|
| Size | 355.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
094b4a2c248f900bad2f4380a95c071bebef0c83e8b3d78eaa6e4f3181c4b749
|
|
BLAKE2b-256 checksum How to use checksums |
4cc81a07cb6482df301ef545c4d2d6b0a6fb0c359843804c7a4da7fe8348c662
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
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 Mar 11, 2026.
Transparency logSecurity for nadeshiko-internal-sdk 1.5.1.dev1773237176
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
Both files in this release have been uploaded with provenance metadata.
Attestation for nadeshiko_internal_sdk-1.5.1.dev1773237176.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 Mar 11, 2026.
Transparency logA 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.