Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lindexi/sm.ms
Sm.ms image upload sdk
https://github.com/lindexi/sm.ms
dotnet dotnet-core dotnet-standard imageshack smms uwp wpf
Last synced: 22 days ago
JSON representation
Sm.ms image upload sdk
- Host: GitHub
- URL: https://github.com/lindexi/sm.ms
- Owner: lindexi
- License: mit
- Created: 2016-06-23T12:40:11.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2022-12-08T12:16:43.000Z (almost 2 years ago)
- Last Synced: 2024-10-05T21:17:27.077Z (about 1 month ago)
- Topics: dotnet, dotnet-core, dotnet-standard, imageshack, smms, uwp, wpf
- Language: C#
- Homepage: https://sm.ms
- Size: 1.22 MB
- Stars: 9
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Sm.ms
| Build | NuGet |
|--|--|
|![](https://github.com/lindexi/Sm.ms/workflows/.NET%20Core/badge.svg)|[![](https://img.shields.io/nuget/v/smms)](https://www.nuget.org/packages/smms)|## Getting Started
NuGet install:
```csharp
dotnet add package smms
```Create a Smms object and set the api token
```csharp
using Sm.msvar smms = new Smms("xxx");
```And you can generate the api token form [https://sm.ms/home/apitoken](https://sm.ms/home/apitoken)
And then you can upload the image and receive the result string
```csharp
var file = new FileInfo(@"F:\lindexi\logo.png");
Console.WriteLine(await smms.UploadImage(file.OpenRead(), file.Name));
```