Threads.Lib 1.0.0-beta-001

This is a prerelease version of Threads.Lib.
There is a newer prerelease version of this package available.
See the version list below for details.
dotnet add package Threads.Lib --version 1.0.0-beta-001                
NuGet\Install-Package Threads.Lib -Version 1.0.0-beta-001                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Threads.Lib" Version="1.0.0-beta-001" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Threads.Lib --version 1.0.0-beta-001                
#r "nuget: Threads.Lib, 1.0.0-beta-001"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Threads.Lib as a Cake Addin
#addin nuget:?package=Threads.Lib&version=1.0.0-beta-001&prerelease

// Install Threads.Lib as a Cake Tool
#tool nuget:?package=Threads.Lib&version=1.0.0-beta-001&prerelease                

F# Library for the Threads API

For the Threads API docs check out https://developers.facebook.com/docs/threads where this is based from.

// script.fsx
#r "nuget: Threads.Lib"
open Threads.Lib
open Threads.Lib.Profile

async {
  let threads = Threads.Create("access-token")
  let! (response: ProfileValue seq) =
    threads.Profile.FetchProfile(
      profileId = "me",
      profileFields = [
        ProfileField.Id
        ProfileField.Username
        ProfileField.ThreadsBiography
        ProfileField.ThreadsProfilePictureUrl
      ]
    )

    printfn $"%A{response}"
    (*
      [ ProfileValue.Id "1234567890"
        ProfileValue.Username "johndoe"
        ProfileValue.ThreadsBiography "I'm a cool guy"
        ProfileValue.ThreadsProfilePictureUrl (Uri "https://example.com/picture.jpg")
      ]
    *)
}
|> Async.RunSynchronously
  • dotnet run script.fsx should print the profile response.

For more information, check out the docs at https://angelmunoz.github.io/Threads.Lib/

Build locally

`dotnet fsi build.fsx -- -p build

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.0.0-beta-002 49 11/5/2024
1.0.0-beta-001 50 11/5/2024

### Added

* - Threads Client
* - Media Service - service to pull down media objects (threads posts)
* - Post Service - service that allows you to create media containers to post threads to threads.net
* - Profile Service - Service that allows you to pull information from a threads profile
* - Reply Management Service - Service that allows you to manage replies to threads or pull replies from threads
* - Insights Service - Service that allows you to pull insights from threads