Repository navigation
v0.8.0
NuGet: https://www.nuget.org/packages/TcgDex.CSharpSdk/0.8.0
dotnet add package TcgDex.CSharpSdk --version 0.8.0
The 1.0 naming pass: every public name now follows the .NET Framework Design Guidelines. Almost
every change is breaking at compile time and none changes what goes over the wire — JSON keys,
request paths and query strings are the same as in 0.7.0. Most upgrades are a find-and-replace from
the table below.
Migration
| 0.7.0 | 0.8.0 |
|---|---|
Serie |
Series |
SerieBrief |
SeriesBrief |
ISerieResource |
ISeriesResource |
ISetResource |
ICardSetResource |
Set (the model) |
CardSet |
SetBrief |
CardSetBrief |
SetAbbreviation |
CardSetAbbreviation |
Set.Serie |
CardSet.Series |
Card.Hp |
Card.HitPoints |
CardFilter.Hp |
CardFilter.HitPoints |
Card.DexId |
Card.DexIds (CardFilter.DexId stays singular: it filters by one id) |
Card.Retreat |
Card.RetreatCost |
CardFilter.Retreat |
CardFilter.RetreatCost |
Card.EvolveFrom |
Card.EvolvesFrom |
CardFilter.EvolveFrom |
CardFilter.EvolvesFrom |
Card.VariantsDetailed |
Card.DetailedVariants |
Card.Legal / CardSet.Legal |
Card.Legality / CardSet.Legality |
DetailedVariant.Stamp |
DetailedVariant.Stamps |
CardCount.FirstEd |
CardCount.FirstEdition |
CardmarketPricing.IdProduct |
CardmarketPricing.ProductId |
CardmarketPricing.Avg |
CardmarketPricing.Average |
CardmarketPricing.Avg1 / Avg7 / Avg30 |
Average1Day / Average7Days / Average30Days |
CardmarketPricing.AvgHolo |
CardmarketPricing.AverageHolo |
CardmarketPricing.Avg1Holo / Avg7Holo / Avg30Holo |
Average1DayHolo / Average7DaysHolo / Average30DaysHolo |
Pricing.Tcgplayer |
Pricing.TcgPlayer |
ThirdParty.Tcgplayer |
ThirdParty.TcgPlayer |
ThirdParty.Cardtrader |
ThirdParty.CardTrader |
TcgDexProblem.Lang |
TcgDexProblem.Language |
TcgDexOptions.GraphQlEndpoint |
TcgDexOptions.GraphQLEndpoint |
TcgDexErrorKind.GraphQlError |
TcgDexErrorKind.GraphQLError (same value, 7; its ToString() changes) |
Random.CardAsync / SetAsync / SerieAsync |
Random.GetCardAsync / GetSetAsync / GetSeriesAsync |
Catalog.CategoriesAsync (and the other twelve) |
Catalog.GetCategoriesAsync (each gains Get) |
Catalog.HitPointsAsync |
Catalog.GetHitPointsAsync |
TcgDexCachingHandler.FreshHits / Revalidations / Misses |
TcgDexCachingHandler.Statistics.FreshHits / .Revalidations / .Misses |
GetImageUrl / GetLogoUrl / GetSymbolUrl returning string? |
the same methods, returning Uri? |
ImageUrl.Build / BuildAsset returning string? |
the same methods, returning Uri? |
new TcgDexApiException(message, statusCode, problem, inner) |
new TcgDexApiException(message, kind, requestUri, statusCode, problem, inner) |
QueryOperator |
removed from the public API (internal) |
Changed
- Breaking: the renames in the table above.
- Breaking: the image URL helpers return
Uri?. A base value that does not form an absolute
http(s) URL now givesnullinstead of a malformed string. - Breaking:
CachedResponseis a class with reference equality rather than a record. It no
longer supportswithor value==; create a new instance with an object initializer. - Breaking:
QueryOperatoris internal. No public member used it. - Breaking: the
TcgDexApiExceptionconstructor taking only a status code is removed. It
producedKind = Unspecified; use the constructor that takes aTcgDexErrorKind. AddTcgDexWithCachingregistersTcgDexCacheOptionsthrough the options pattern, so
Configure<TcgDexCacheOptions>, anappsettings.jsonbinding andIOptions<TcgDexCacheOptions>
now work alongside theconfigureCachedelegate. Previously only the delegate was applied.
The merged options are validated at start-up, likeTcgDexOptions: aMaxEntriesbelow 1 or a
negative time-to-live fails withOptionsValidationException.- An unreadable
updatedtimestamp on a card or a pricing block now reads asnull, as
ReleaseDatealready did, instead of failing the whole card.