StockSharp.Messages
5.0.251
Prefix Reserved
dotnet add package StockSharp.Messages --version 5.0.251
NuGet\Install-Package StockSharp.Messages -Version 5.0.251
<PackageReference Include="StockSharp.Messages" Version="5.0.251" />
<PackageVersion Include="StockSharp.Messages" Version="5.0.251" />
<PackageReference Include="StockSharp.Messages" />
paket add StockSharp.Messages --version 5.0.251
#r "nuget: StockSharp.Messages, 5.0.251"
#:package StockSharp.Messages@5.0.251
#addin nuget:?package=StockSharp.Messages&version=5.0.251
#tool nuget:?package=StockSharp.Messages&version=5.0.251
StockSharp Messages Library
The Messages project contains the essential message definitions shared across the StockSharp (S#) trading framework. Messages are the contracts used by connectors, adapters and other services for all interactions such as connecting to brokers, requesting market data or placing orders.
Overview
- Message Types Enumeration –
MessageTypeslists every supported message kind. - Base Classes – classes like
Message,BaseConnectionMessageandBaseSubscriptionMessageprovide common fields and behaviour. - Asynchronous Processing –
MessageAdapterandAsyncMessageProcessorhandle messages asynchronously. - Utility Helpers – classes such as
ReConnectionSettingscontrol reconnection and subscription options.
Core Messages
The library defines messages for all major trading activities:
- Connection –
ConnectMessage,DisconnectMessage,ConnectionLostMessageandConnectionRestoredMessage. - Security Information –
SecurityMessage,BoardMessageandBoardStateMessage. - Market Data –
MarketDataMessage,Level1ChangeMessage,QuoteChangeMessage,TimeFrameCandleMessageand related candle messages. - Orders and Trades –
OrderRegisterMessage,OrderReplaceMessage,OrderCancelMessage,OrderGroupCancelMessage,OrderStatusMessageandExecutionMessage. - Portfolio and Positions –
PortfolioMessage,PortfolioLookupMessageandPositionChangeMessage. - Service Messages –
TimeMessage,NewsMessage,ErrorMessageand others.
The project targets .NET Standard 2.0 and .NET 6.0 for cross-platform compatibility.
Usage Example
Below is a minimal example of creating a market data subscription message:
using StockSharp.Messages;
var mdMessage = new MarketDataMessage
{
DataType2 = DataType.Ticks,
IsSubscribe = true,
TransactionId = 1,
SecurityId = new SecurityId
{
SecurityCode = "AAPL",
BoardCode = "NASDAQ"
}
};
Such messages are passed to an adapter, which forwards them to the broker or data provider.
Documentation
Further details on messages and architecture can be found in the StockSharp documentation.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Ecng.Linq (>= 1.0.194)
- Ecng.Logging (>= 1.0.203)
- StockSharp.Localization (>= 5.0.239)
NuGet packages (410)
Showing the top 5 NuGet packages that depend on StockSharp.Messages:
| Package | Downloads |
|---|---|
|
StockSharp.BusinessEntities
Trading entities (security, trade etc.). More info on web site https://stocksharp.com/store/ |
|
|
StockSharp.Configuration
Configuration components. More info on web site https://stocksharp.com/store/ |
|
|
StockSharp.Fix
FIX/FAST |
|
|
StockSharp.Fix.Core
Fix core. More info on web site https://stocksharp.com/store/ |
|
|
StockSharp.Server.Core
Core server components. More info on web site https://stocksharp.com/store/ |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 5.0.251 | 0 | 10/24/2026 |
| 5.0.250 | 266 | 9/30/2026 |
| 5.0.249 | 601 | 9/13/2026 |
| 5.0.248 | 455 | 9/9/2026 |
| 5.0.247 | 173 | 8/31/2026 |
| 5.0.246 | 4,074 | 8/26/2026 |
| 5.0.245 | 378 | 8/26/2026 |
| 5.0.244 | 1,274 | 8/20/2026 |
| 5.0.243 | 552 | 8/18/2026 |
| 5.0.242 | 432 | 8/15/2026 |
| 5.0.241 | 391 | 8/11/2026 |
| 5.0.240 | 229 | 8/5/2026 |
| 5.0.239 | 419 | 7/30/2026 |
| 5.0.238 | 348 | 7/28/2026 |
| 5.0.237 | 166 | 7/17/2026 |
| 5.0.236 | 152 | 7/9/2026 |
| 5.0.235 | 184 | 6/21/2026 |
| 5.0.234 | 250 | 6/17/2026 |
| 5.0.233 | 150 | 6/14/2026 |
| 5.0.232 | 206 | 6/8/2026 |
Unit properties that refuse no value are marked required
Build requested candle series with calendar bounds and accurate source updates
Localize public core enum captions with Display resources
Carry the order's own id on its registration
Name the overload a doc comment of the order book holder refers to
Fold an order book change without stating the whole book it leaves
Name boards and board states in words
Unwind the blocking waits left by the async rework and fix what it uncovered
Add walk-forward optimization, a market profile, three statistics and candle spread options
Move instrument lookups and persistence to async
Answer an unsubscribe that arrives after the connection ended
Updated Ecng.Linq to 1.0.194.
Updated Ecng.Logging to 1.0.203.