package com.balancedpayments;

import com.balancedpayments.core.Resource;
import com.balancedpayments.core.ResourceCollection;
import com.balancedpayments.core.ResourceField;
import com.balancedpayments.core.ResourceQuery;

import java.util.Date;


public class Dispute extends Resource {

    public static final String resource_href = "/disputes";

    @ResourceField()
    public Integer amount;

    @ResourceField()
    public String currency;

    @ResourceField()
    public Date initianted_at;

    @ResourceField()
    public String href;

    @ResourceField()
    public String reason;

    @ResourceField()
    public Date respond_by;

    @ResourceField()
    public String status;

    @ResourceField(field="disputes.events")
    public Event.Collection events;

    @ResourceField(field="disputes.transaction")
    public Debit transaction;


    public static class Collection extends ResourceCollection<Dispute> {
        public Collection(String uri) {
            super(Dispute.class, uri);
        }
    }
    public static ResourceQuery<Dispute> query() {
        return new ResourceQuery<Dispute>(Dispute.class, resource_href);
    }
}

@@ -215,16 +215,62 @@
 ceQuery;
+%0Aimport com.balancedpayments.errors.HTTPError;
 %0A%0Aimport
@@ -896,16 +896,93 @@
 tion;%0A%0A%0A
+    public Dispute(String uri) throws HTTPError %7B%0A        super(uri);%0A    %7D%0A%0A
     publ

Add constructor to Dispute so fetches work