Skip to content

service stopped working #2

@spacedw

Description

@spacedw

now the threads api requires a header and an additional parameter to continue working this service

Captura de pantalla 2023-07-11 a la(s) 7 33 48 p m

solution to this:
added a header and parameter lsd

//in consts.ts
export const THREADS_FB_LSD = "jdFoLBsUcm9h-j90PeanuC"


//in fetch.js
const fetchBase = ({ documentId, variables }) => {
  return fetch(GRAPHQL_ENDPOINT, {
    method: 'POST',
    headers: {
      'content-type': 'application/x-www-form-urlencoded',
      'user-agent': 'Threads API midu client',
      'x-ig-app-id': THREADS_APP_ID,
      'x-fb-lsd': THREADS_FB_LSD
    },
    body: `variables=${JSON.stringify(variables)}&doc_id=${documentId}&lsd=${THREADS_FB_LSD}`
    })
  .then(response => response.json())
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions