nkte8 / skyshare

Bluesky API Client with OGP generator.

Home Page:https://skyshare.uk/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Skyshare is web application that BlueSky user saves their time of boring SNS X.com(Twitter).

How works

Skyshare post your post to Bluesky with AT Protocol.
for twitter, because of X taxes, Skyshare present Post Link: Like that, can only with media by OGP image.

AT Protocol

Because of bluesky official typescript client seems not available works on React, Skyshare uses REST API directry by fetch API like that...

import endpoint_url, { com_atproto } from "./base"
import mtype from "./models/createSession.json"
import etype from "./models/error.json"
const endpoint = endpoint_url(com_atproto.server.createSession)

export const api = async ({
    identifier,
    password,
}:{
    identifier: string,
    password: string,
}): Promise<typeof mtype & typeof etype> => fetch(endpoint,
    {
        method: 'POST',
        headers: { 'Content-Type': 'application/json' },
        body: JSON.stringify(
            {
                identifier: identifier,
                password: password,
            })
    }).then((response) => response.json()
    ).catch(() => {})

export default api

more info

Zenn article: for japanese developer

About

Bluesky API Client with OGP generator.

https://skyshare.uk/

License:BSD 3-Clause "New" or "Revised" License


Languages

Language:TypeScript 83.5%Language:Astro 14.1%Language:JavaScript 2.3%Language:Shell 0.1%