Skip to content

Releases: bvdcode/Blink.NET

Release 0.1.14

10 Nov 06:26

Choose a tag to compare

Update X-Blink-Time-Zone header to use UTC

The code change updates the `X-Blink-Time-Zone` HTTP header value from "America/Los_Angeles" to "UTC". This means that the application will now use Coordinated Universal Time (UTC) instead of the Pacific Time Zone (America/Los_Angeles) for the `X-Blink-Time-Zone` header in its HTTP requests.

Release 0.1.13

30 Oct 04:34

Choose a tag to compare

Refactor authorization and client identification

Modified `Program.cs` to always reauthorize the client by setting `reauth: true` in the `AuthorizeAsync` method call. Changed the reauthorization condition to check for client verification instead of an empty token. Removed the `Token` property from the `Secrets` class in `Secrets.cs`. Added a `UniqueId` property to the `BlinkClient` class in `BlinkClient.cs` to generate unique identifiers for each client instance, replacing the hardcoded `_uniqueId` value.

Release 0.1.12

30 Oct 01:53

Choose a tag to compare

Implement IBlinkClient interface in BlinkClient

The BlinkClient class in BlinkClient.cs has been modified to implement the IBlinkClient interface. A new file, IBlinkClient.cs, has been introduced, defining the IBlinkClient interface with several asynchronous methods for interacting with the Blink API, such as AuthorizeAsync, DeleteVideoAsync, GetDashboardAsync, GetVideoAsync, GetVideosAsync, and VerifyPinAsync. It also includes a property GeneralSleepTime to control the delay required to prevent the server from returning an empty response.

Release 0.1.11

22 Oct 23:08

Choose a tag to compare

Refactor HTTP client handling and centralize base URL

Introduce a new private constant `_baseUrl` for the Blink API.
Replace direct `_http` usage with `GetHttpClient()` method.
Update `CreateHttpClient` to have a default `token` value.
Ensure `_http` is initialized with `_baseUrl` in `GetHttpClient()`.
Centralize `HttpClient` creation and retrieval for consistency.

Release 0.1.10

27 Sep 08:19

Choose a tag to compare

Update unique_id in login API to include app name and version

The code change updates the `unique_id` field in the request body for the login API call. Previously, the `unique_id` was set to `_userAgent`. Now, it is set to a string that combines the name and version of the entry assembly, formatted as "AppName vVersion".

This modification ensures that the `unique_id` sent in the login request is more descriptive, including both the application name and its version, which can be useful for tracking and debugging purposes.

Release 0.1.9

27 Sep 08:08

Choose a tag to compare

Update HTTP client headers and user agent in BlinkClient.cs

Changed the token header key to uppercase ("TOKEN-AUTH") to ensure server recognition. Updated the user agent string to a static value ("35.1ANDROID_28746173") for standardization and compliance with server requirements.

Release 0.1.8

25 Sep 22:35

Choose a tag to compare

Change package icon

Release 0.1.7

24 Sep 09:40

Choose a tag to compare

Add retry mechanism to GetVideoAsync in BlinkClient

- Added `System.Net.Mime` namespace to `BlinkClient.cs`.
- Modified `GetVideoAsync` to include optional `tryCount` parameter.
- Implemented retry logic in `GetVideoAsync`:
  - Attempts to retrieve video up to `tryCount` times.
  - Posts to URL and waits for `GeneralSleepTime` before retrying.
  - Returns video as byte array if content type is "video/mp4".
  - Throws `BlinkClientException` if content type is not "video/mp4" after retries.

Release 0.1.6

24 Sep 09:26

Choose a tag to compare

Improve error message in BlinkClient.cs for content type

Updated the exception message in BlinkClient.cs to include the
actual content type received instead of the video.ManifestId
when the content type is not "video/mp4". This change provides
more relevant information about the failure.

Release 0.1.5

24 Sep 09:13

Choose a tag to compare

Enhance error handling and disable video deletion

Improved error handling and validation in `GetVideoAsync` and `DeleteVideoAsync` methods of `BlinkClient.cs` by adding checks for authorization and video data integrity, throwing `BlinkClientException` when necessary. Enhanced exception messages for better debugging. Temporarily disabled video deletion in `Program.cs` by commenting out the `await client.DeleteVideoAsync(video);` line.