# clerk-api
A Reflex custom component for integrating Clerk authentication into a Reflex application.
See a demo of it in action [here](https://clerk-reflex-api.adventuresoftim.com).
Documentation will soon be available [here](https://timchild.github.io/reflex-clerk-api/)
## Installation
Any of:
```bash
uv add reflex-clerk-api
pip install reflex-clerk-api
poetry add reflex-clerk-api
```
## Usage
```python
import reflex_clerk_api as clerk
def index() -> rx.Component:
return clerk.clerk_provider(
rx.container(
clerk.clerk_loaded(
clerk.signed_in(
clerk.sign_on(
rx.button("Sign out"),
),
),
clerk.signed_out(
rx.button("Sign in"),
),
),
),
publishable_key=os.environ["CLERK_PUBLISHABLE_KEY"],
secret_key=os.environ["CLERK_SECRET_KEY"],
register_user_state=True,
)
```
Raw data
{
"_id": null,
"home_page": null,
"name": "reflex-clerk-api",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.10",
"maintainer_email": null,
"keywords": "reflex, reflex-custom-components, clerk, clerk-backend-api",
"author": null,
"author_email": "Tim Child <timjchild@gmail.com>",
"download_url": "https://files.pythonhosted.org/packages/33/61/f9b89a6b4883ab9a9174000e787217251ccc3e77d42e056efcab2ab10ce1/reflex_clerk_api-0.0.1.tar.gz",
"platform": null,
"description": "# clerk-api\n\nA Reflex custom component for integrating Clerk authentication into a Reflex application.\n\nSee a demo of it in action [here](https://clerk-reflex-api.adventuresoftim.com).\n\nDocumentation will soon be available [here](https://timchild.github.io/reflex-clerk-api/)\n\n## Installation\n\nAny of:\n\n```bash\nuv add reflex-clerk-api\n\npip install reflex-clerk-api\n\npoetry add reflex-clerk-api\n```\n\n## Usage\n\n```python\nimport reflex_clerk_api as clerk\n\ndef index() -> rx.Component:\n return clerk.clerk_provider(\n rx.container(\n clerk.clerk_loaded(\n clerk.signed_in(\n clerk.sign_on(\n rx.button(\"Sign out\"),\n ),\n ),\n clerk.signed_out(\n rx.button(\"Sign in\"),\n ),\n ),\n ),\n publishable_key=os.environ[\"CLERK_PUBLISHABLE_KEY\"],\n secret_key=os.environ[\"CLERK_SECRET_KEY\"],\n register_user_state=True,\n )\n```\n",
"bugtrack_url": null,
"license": "Apache-2.0",
"summary": "Reflex custom component wrapping @clerk/clerk-react and integrating the clerk-backend-api",
"version": "0.0.1",
"project_urls": null,
"split_keywords": [
"reflex",
" reflex-custom-components",
" clerk",
" clerk-backend-api"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "780ceba070920f2ce2f6fedeb8682b4389cd70db7fc749b148677e05ff29817b",
"md5": "4d724297edccf67e8b274bf0b2b00815",
"sha256": "798232a391b3858c64a1873b255023c0f0649c421ec37ea860fd69a187a36e59"
},
"downloads": -1,
"filename": "reflex_clerk_api-0.0.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "4d724297edccf67e8b274bf0b2b00815",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.10",
"size": 8868,
"upload_time": "2025-03-22T01:48:05",
"upload_time_iso_8601": "2025-03-22T01:48:05.386075Z",
"url": "https://files.pythonhosted.org/packages/78/0c/eba070920f2ce2f6fedeb8682b4389cd70db7fc749b148677e05ff29817b/reflex_clerk_api-0.0.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "3361f9b89a6b4883ab9a9174000e787217251ccc3e77d42e056efcab2ab10ce1",
"md5": "3ae5abf9353ebc68595b221348bb59a8",
"sha256": "55167a3ef027241474617a454d8ec5f27650b4b58a0bcfa06074f1cbd8db2f58"
},
"downloads": -1,
"filename": "reflex_clerk_api-0.0.1.tar.gz",
"has_sig": false,
"md5_digest": "3ae5abf9353ebc68595b221348bb59a8",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.10",
"size": 7979,
"upload_time": "2025-03-22T01:48:06",
"upload_time_iso_8601": "2025-03-22T01:48:06.410784Z",
"url": "https://files.pythonhosted.org/packages/33/61/f9b89a6b4883ab9a9174000e787217251ccc3e77d42e056efcab2ab10ce1/reflex_clerk_api-0.0.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-03-22 01:48:06",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "reflex-clerk-api"
}