bsky-bridge


Namebsky-bridge JSON
Version 1.0.3 PyPI version JSON
download
home_pagehttps://github.com/4xe1/bsky-bridge
SummaryA Python interface for interacting with the BlueSky social network's API.
upload_time2024-10-30 22:47:14
maintainerNone
docs_urlNone
authorAxel Merlo
requires_python>=3.6
licenseNone
keywords bluesky api python bridge social network bluesky api social network api bluesky python
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
              # bsky-bridge: A Python Library for the BlueSky API

  `bsky-bridge` is a Python library designed to bridge the interaction between Python applications and the BlueSky Social Network via its API.

  ## Table of Contents

  - [Features](#features)
  - [Installation](#installation)
  - [Usage](#usage)
    - [Creating a Session](#creating-a-session)
    - [Posting Content](#posting-content)
    - [Posting Images](#posting-images)
  - [Contribution](#contribution)
  - [License](#license)

  ## Features

  - Easy authentication with the BlueSky API.
  - Functions to post text and images to BlueSky via the API.

  ## Installation

  ```bash
  pip install bsky-bridge
  ```

  ## Usage

  ### Creating a Session

  Start by establishing a session with your BlueSky handle and **App passwords** *(To be created in your account settings)*:

  ```python
  from bsky_bridge import BskySession

  session = BskySession("your_handle.bsky.social", "your_APPpassword")
  ```

  ### Posting Content

  After initializing a session, you can post text to BlueSky:

  ```python
  from bsky_bridge import BskySession, post_text

  session = BskySession("your_handle.bsky.social", "your_APPpassword")

  response = post_text(session, "Hello BlueSky!")
  print(response)
  ```

  ### Posting Images

  To post images along with text, you can use the `post_image` method:

  ```python
  from bsky_bridge import BskySession, post_image

  session = BskySession("your_handle.bsky.social", "your_APPpassword")

  postText = "Check out this cool image!"
  imagePath = "path_to_your_image.jpeg"
  altText = "An awesome image"
  response = post_image(session, postText, imagePath, altText)
  print(response)
  ```

  **Note**: The library automatically handles resizing and compressing larger images to ensure they do not exceed 1 MB in size, all while maintaining a quality balance. This ensures efficient and quick image uploads.

  ## Contribution

  Contributions are welcome! Please submit issues for any bug or problem you discover, and pull requests for new features or fixes.

  ## License

  [MIT License](LICENSE)

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/4xe1/bsky-bridge",
    "name": "bsky-bridge",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.6",
    "maintainer_email": null,
    "keywords": "bluesky, api, python, bridge, social network, bluesky api, social network api, bluesky python",
    "author": "Axel Merlo",
    "author_email": "contact@axelm.fr",
    "download_url": "https://files.pythonhosted.org/packages/78/89/1373a23ffa9280d21e138f1ba703eea36002934370fd7d17ceeb7f5183a2/bsky_bridge-1.0.3.tar.gz",
    "platform": null,
    "description": "  # bsky-bridge: A Python Library for the BlueSky API\n\n  `bsky-bridge` is a Python library designed to bridge the interaction between Python applications and the BlueSky Social Network via its API.\n\n  ## Table of Contents\n\n  - [Features](#features)\n  - [Installation](#installation)\n  - [Usage](#usage)\n    - [Creating a Session](#creating-a-session)\n    - [Posting Content](#posting-content)\n    - [Posting Images](#posting-images)\n  - [Contribution](#contribution)\n  - [License](#license)\n\n  ## Features\n\n  - Easy authentication with the BlueSky API.\n  - Functions to post text and images to BlueSky via the API.\n\n  ## Installation\n\n  ```bash\n  pip install bsky-bridge\n  ```\n\n  ## Usage\n\n  ### Creating a Session\n\n  Start by establishing a session with your BlueSky handle and **App passwords** *(To be created in your account settings)*:\n\n  ```python\n  from bsky_bridge import BskySession\n\n  session = BskySession(\"your_handle.bsky.social\", \"your_APPpassword\")\n  ```\n\n  ### Posting Content\n\n  After initializing a session, you can post text to BlueSky:\n\n  ```python\n  from bsky_bridge import BskySession, post_text\n\n  session = BskySession(\"your_handle.bsky.social\", \"your_APPpassword\")\n\n  response = post_text(session, \"Hello BlueSky!\")\n  print(response)\n  ```\n\n  ### Posting Images\n\n  To post images along with text, you can use the `post_image` method:\n\n  ```python\n  from bsky_bridge import BskySession, post_image\n\n  session = BskySession(\"your_handle.bsky.social\", \"your_APPpassword\")\n\n  postText = \"Check out this cool image!\"\n  imagePath = \"path_to_your_image.jpeg\"\n  altText = \"An awesome image\"\n  response = post_image(session, postText, imagePath, altText)\n  print(response)\n  ```\n\n  **Note**: The library automatically handles resizing and compressing larger images to ensure they do not exceed 1 MB in size, all while maintaining a quality balance. This ensures efficient and quick image uploads.\n\n  ## Contribution\n\n  Contributions are welcome! Please submit issues for any bug or problem you discover, and pull requests for new features or fixes.\n\n  ## License\n\n  [MIT License](LICENSE)\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A Python interface for interacting with the BlueSky social network's API.",
    "version": "1.0.3",
    "project_urls": {
        "Homepage": "https://github.com/4xe1/bsky-bridge"
    },
    "split_keywords": [
        "bluesky",
        " api",
        " python",
        " bridge",
        " social network",
        " bluesky api",
        " social network api",
        " bluesky python"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f2a5e9cd085fe266b09c92eb8a39f9fdda3f7492ea32838c73d9654f3f3bb135",
                "md5": "053d675122450f56a10cc4300c240dad",
                "sha256": "9fec433c982c8f2ad40e353ed114f39ef06159e3edcb33773075742c44310c42"
            },
            "downloads": -1,
            "filename": "bsky_bridge-1.0.3-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "053d675122450f56a10cc4300c240dad",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.6",
            "size": 6549,
            "upload_time": "2024-10-30T22:47:13",
            "upload_time_iso_8601": "2024-10-30T22:47:13.486439Z",
            "url": "https://files.pythonhosted.org/packages/f2/a5/e9cd085fe266b09c92eb8a39f9fdda3f7492ea32838c73d9654f3f3bb135/bsky_bridge-1.0.3-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "78891373a23ffa9280d21e138f1ba703eea36002934370fd7d17ceeb7f5183a2",
                "md5": "3b7c24fe77cbcbbb2131187bf4b7a2e8",
                "sha256": "3a80756ff8be4f59ff4f53f4fbe9bfbad876fcdb713f8ad8d1073c4926812a1e"
            },
            "downloads": -1,
            "filename": "bsky_bridge-1.0.3.tar.gz",
            "has_sig": false,
            "md5_digest": "3b7c24fe77cbcbbb2131187bf4b7a2e8",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6",
            "size": 5371,
            "upload_time": "2024-10-30T22:47:14",
            "upload_time_iso_8601": "2024-10-30T22:47:14.736813Z",
            "url": "https://files.pythonhosted.org/packages/78/89/1373a23ffa9280d21e138f1ba703eea36002934370fd7d17ceeb7f5183a2/bsky_bridge-1.0.3.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-10-30 22:47:14",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "4xe1",
    "github_project": "bsky-bridge",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "bsky-bridge"
}
        
Elapsed time: 0.40819s