/**
 * Copyright (C) 2016 Bruno Candido Volpato da Cunha (brunocvcunha@gmail.com)
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *         http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package org.brunocvcunha.instagram4j.requests;

import org.brunocvcunha.instagram4j.requests.payload.StatusResult;

import lombok.SneakyThrows;

/**
 * Timeline Feed Request
 * 
 * @author Bruno Candido Volpato da Cunha
 *
 */
public class InstagramTimelineFeedRequest extends InstagramGetRequest<StatusResult> {

    @Override
    public String getUrl() {
        return "feed/timeline/";
    }

    @Override
    public String getPayload() {
        return null;
    }

    @Override
    @SneakyThrows
    public StatusResult parseResult(int statusCode, String content) {
        return parseJson(statusCode, content, StatusResult.class);
    }

}

@@ -955,16 +955,47 @@
 ult%3E %7B%0A%0A
+    private String maxId;%0A    %0A
     @Ove
@@ -1037,22 +1037,28 @@
         
-return
+String url =
  %22feed/t
@@ -1068,16 +1068,143 @@
 line/%22;%0A
+        if (maxId != null && !maxId.isEmpty()) %7B%0A            url += %22&max_id=%22 + maxId;%0A        %7D%0A        %0A        return url;%0A
     %7D%0A%0A 

allow max id on timeline request