Skip to content

Commit

Permalink
Merge pull request #29 from cardano-community/address-asset-fix
Browse files Browse the repository at this point in the history
corrected the response model for address assets
  • Loading branch information
nothingalike authored Dec 6, 2023
2 parents d794f00 + 5e15aaf commit 3a5c58a
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 7 deletions.
2 changes: 1 addition & 1 deletion CardanoSharp.Koios.Client/CardanoSharp.Koios.Client.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
<Version>2.0.0</Version>
<Version>2.1.0</Version>
<LangVersion>8.0</LangVersion>
</PropertyGroup>

Expand Down
6 changes: 1 addition & 5 deletions CardanoSharp.Koios.Client/Contracts/AddressAssetGroup.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,10 @@
namespace CardanoSharp.Koios.Client.Contracts
{
[DataContract]
public class AddressAssetGroup
public class AddressAssetGroup: AssetListInformation
{
[DataMember]
[JsonPropertyName("address")]
public string? Address { get; set; }

[DataMember]
[JsonPropertyName("asset_list")]
public AssetListInformation[]? Assets { get; set; }
}
}
2 changes: 1 addition & 1 deletion CardanoSharp.Koios.Sample/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@

// Get Address Assets
Console.WriteLine("Get Address Assets");
var addressAssets = addressClient.GetAddressAssets(addressBulkRequest).Result;
var addressAssets = addressClient.GetAddressAssets(new AddressBulkRequest() { Addresses = new List<String>() {"addr1qy2jt0qpqz2z2z9zx5w4xemekkce7yderz53kjue53lpqv90lkfa9sgrfjuz6uvt4uqtrqhl2kj0a9lnr9ndzutx32gqleeckv"}}).Result;
foreach (var aa in addressAssets.Content)
{
Console.WriteLine(JsonSerializer.Serialize(aa));
Expand Down

0 comments on commit 3a5c58a

Please sign in to comment.