Skip to content

InsightApiObject has incorrect type for Category #164

@Nemjit03

Description

@Nemjit03

The category object in Bunq.Sdk.Model.Generated.Endpoint.InsightApiObject has type string

This should be something like:

public class CategoryObject
{
    [JsonProperty(PropertyName = "category")]
    public string Category { get; set; }
    
    [JsonProperty(PropertyName = "type")]
    public string Type { get; set; }

    [JsonProperty(PropertyName = "status")]
    public string Status { get; set; }

    [JsonProperty(PropertyName = "description")]
    public string Description { get; set; }

    [JsonProperty(PropertyName = "description_translated")]
    public string DescriptionTranslated { get; set; }

    [JsonProperty(PropertyName = "color")]
    public string Color { get; set; }

    [JsonProperty(PropertyName = "icon")]
    public string Icon { get; set; }
    
    [JsonProperty(PropertyName = "order")]
    public int Order { get; set; }
}

As one response as raw object returned to me was:

{
    "InsightCategory" : {
      "category" : {
        "category" : "GROCERIES",
        "type" : "GENERAL",
        "status" : "ACTIVE",
        "order" : 2,
        "description" : "Groceries",
        "description_translated" : "Groceries",
        "color" : "#FAAA00",
        "icon" : "GROCERIES"
      },
      "amount_total" : {
        "currency" : "EUR",
        "value" : "8.71"
      },
      "number_of_transactions" : 1
    }
  }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions