Jump to content
View in the app

A better way to browse. Learn more.

OSBot :: 2007 OSRS Botting

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

G.E API and Items image - Question

Featured Replies

Hello everyone 👋,

I'm currently working on a project and I'm having a hard time finding an update G.E API for osrs that contains the product image so I can have both updated value and image for my website, do you guys have any idea where I can get both?

For the G.E API, I'm using the one provided by rsbuddy (open for better suggestions) and for the item image, I'd need to make a call to get the item icon from services.runescape

Do you guys have any suggestion to make this process easier? 

There is only the offical and the rsbuddy ge api.

And the rsbuddy ge api is kinda garbage since rsbuddy has a super low playercount and anyone can just send them false data and manipulate prices (which is why runelite doesnt track their users ge data).

 

 

  • Author

Fair enough. I was expecting rsbuddy to be quite popular and reliable since everyone suggests to use that instead! Thanks for the help guys, will take a look on the reddit post suggested by @Apaec

  • 3 months later...
  • Author

Hello everyone,

I'd like to revive this topic as me and some friends are getting back to this idea to play around. Unfortunately, the reddit post provided by Apaec is a bit outdated, is there any other suggestion available at the moment?

I'm trying to get high quality images of each item, like the ones provided by https://oldschool.runescape.wiki/ and a valid G.E API to fetch the prices, so the problem here is:

  • Finding the items database;
  • Link them to a valid website with images that we can download;
  • G.E value of each one of these items.

Do you have any suggestion for that?

This is my code for One of my ge merchers

I cant find my Id-> price code

https://prnt.sc/sdtqu3

https://prnt.sc/sdtr35

Query  -> sub-set of data-base


        textField1.getDocument().addDocumentListener(new DocumentListener(){


            @Override
            public void insertUpdate(DocumentEvent e) {
                String text = textField1.getText();

                if (text.trim().length() == 0) {
                    rowSorter.setRowFilter(null);
                } else {
                    rowSorter.setRowFilter(RowFilter.regexFilter("(?i)" + text));
                }
            }

            @Override
            public void removeUpdate(DocumentEvent e) {
                String text = textField1.getText();

                if (text.trim().length() == 0) {
                    rowSorter.setRowFilter(null);
                } else {
                    rowSorter.setRowFilter(RowFilter.regexFilter("(?i)" + text));
                }
            }

            @Override
            public void changedUpdate(DocumentEvent e) {
                throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
            }

        });

 

Clicking on item -> name/id

   table1.addMouseListener(new java.awt.event.MouseAdapter() {
            @Override
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                int row = table1.rowAtPoint(evt.getPoint());
                int col = table1.columnAtPoint(evt.getPoint());
                if (row >= 0 && col >= 0) {
                    table1.getValueAt( row,  col);
                    ItemName.setText((String) table1.getValueAt( row,  0));


                }
            }
        });

 

 

 

Id-> Item (might want to add 1 more hash map that is <string,Items> to do name-> item->id )

public class ItemGuide {
    private static final Map<Long, Item> allGEItems = new HashMap<>();
    private static final List<Object[]> GeItems= new ArrayList<>();



    public static Object[][] getAllGEItems() {
        if (allGEItems.isEmpty()) {

            File summaryFile = Paths.get(System.getProperty("user.home"), "OSBot", "Data", "items-cache-data.json").toFile();
            try {
                if (!summaryFile.exists()) {

                    URL website = new URL("https://raw.githubusercontent.com/osrsbox/osrsbox-db/master/data/items/items-cache-data.json");
                    ReadableByteChannel rbc = Channels.newChannel(website.openStream());
                    FileOutputStream fos = new FileOutputStream(summaryFile);
                    fos.getChannel().transferFrom(rbc, 0, Long.MAX_VALUE);
                }

                try (FileReader fileReader = new FileReader(summaryFile)) {
                    JSONObject jsonObject = (JSONObject) (new JSONParser().parse(fileReader));
                    for (Object value : jsonObject.values()) {
                        JSONObject item = (JSONObject) value;
                        if ((Boolean) item.get("tradeable_on_ge")){

                            allGEItems.put((Long) item.get("id"),new Item().setId((Long) item.get("id"))
                                    .setMembers((Boolean) item.get("members"))
                                    .setName((String) item.get("name"))
                            );

                        }
                    }

                }
            } catch (IOException | ParseException e) {
                e.printStackTrace();
            }
             summaryFile = Paths.get(System.getProperty("user.home"), "OSBot", "Data", "ge-limits-ids.json").toFile();
            try {
                if (!summaryFile.exists()) {
                    URL website = new URL("https://raw.githubusercontent.com/osrsbox/osrsbox-db/master/data/items/ge-limits-ids.json");
                    ReadableByteChannel rbc = Channels.newChannel(website.openStream());
                    FileOutputStream fos = new FileOutputStream(summaryFile);
                    fos.getChannel().transferFrom(rbc, 0, Long.MAX_VALUE);
                }
                try (FileReader fileReader = new FileReader(summaryFile)) {
                    JSONObject jsonObject = (JSONObject) (new JSONParser().parse(fileReader));
                    for (Object value : jsonObject.keySet()) {

                        if (allGEItems.containsKey(Long.valueOf((String) value) )){

                            System.out.println(jsonObject.get(value));

                            if (jsonObject.get(value)!=null){

                                allGEItems.get(Long.valueOf((String) value)).setBuyLimit((Long) jsonObject.get(value));

                            }else {
                                allGEItems.get(Long.valueOf((String) value)).setBuyLimit(-1);



                            }

                        }

                    }

                }
            } catch (IOException | ParseException e) {
                e.printStackTrace();
            }



        }
        allGEItems.values().forEach(s->GeItems.add(s.getItem()));
        Object[][] array2d = GeItems.toArray(new Object[GeItems.size()][]);
        return array2d;
    }


    public static Map<Long, Item> getGeItems() {
        if (allGEItems.isEmpty()){
            getAllGEItems();

        }
        return allGEItems;
    }
}

 

 

 

Id -> Image

   Image image =null;

    private void drawitem(){
        if (image ==null){

            URL url = null;

            try {
                url = new URL("https://rsbuddy.com/items/" + itemid+".png");
            } catch (MalformedURLException e) {
                e.printStackTrace();
            }

            try {
                image = ImageIO.read(url);

            } catch (IOException e) {
                e.printStackTrace();
            }

        }
        Graphics g = c.getGraphics();
        Graphics2D g2 = (Graphics2D) g;
        if (image!=null){

            g.drawImage(image, 55, 50,60,60,null );
            g.setColor(lowlites);
            g2.setStroke(new BasicStroke(3));

        }else {
            drawText("ERROR", 50 ,50,Color.white,font1);
        }
        
        g2.setStroke(new BasicStroke(1));
        g.setColor(Color.black);
        g2.draw(new RoundRectangle2D.Double(50, 50, 60, 60, 10, 10));

    }

 

 

Edited by Nbacon

  • Author
11 hours ago, Nbacon said:

This is my code for One of my ge merchers

I cant find my Id-> price code

https://prnt.sc/sdtqu3

https://prnt.sc/sdtr35

Query  -> sub-set of data-base



        textField1.getDocument().addDocumentListener(new DocumentListener(){


            @Override
            public void insertUpdate(DocumentEvent e) {
                String text = textField1.getText();

                if (text.trim().length() == 0) {
                    rowSorter.setRowFilter(null);
                } else {
                    rowSorter.setRowFilter(RowFilter.regexFilter("(?i)" + text));
                }
            }

            @Override
            public void removeUpdate(DocumentEvent e) {
                String text = textField1.getText();

                if (text.trim().length() == 0) {
                    rowSorter.setRowFilter(null);
                } else {
                    rowSorter.setRowFilter(RowFilter.regexFilter("(?i)" + text));
                }
            }

            @Override
            public void changedUpdate(DocumentEvent e) {
                throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
            }

        });

 

Clicking on item -> name/id


   table1.addMouseListener(new java.awt.event.MouseAdapter() {
            @Override
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                int row = table1.rowAtPoint(evt.getPoint());
                int col = table1.columnAtPoint(evt.getPoint());
                if (row >= 0 && col >= 0) {
                    table1.getValueAt( row,  col);
                    ItemName.setText((String) table1.getValueAt( row,  0));


                }
            }
        });

 

 

 

Id-> Item (might want to add 1 more hash map that is <string,Items> to do name-> item->id )


public class ItemGuide {
    private static final Map<Long, Item> allGEItems = new HashMap<>();
    private static final List<Object[]> GeItems= new ArrayList<>();



    public static Object[][] getAllGEItems() {
        if (allGEItems.isEmpty()) {

            File summaryFile = Paths.get(System.getProperty("user.home"), "OSBot", "Data", "items-cache-data.json").toFile();
            try {
                if (!summaryFile.exists()) {

                    URL website = new URL("https://raw.githubusercontent.com/osrsbox/osrsbox-db/master/data/items/items-cache-data.json");
                    ReadableByteChannel rbc = Channels.newChannel(website.openStream());
                    FileOutputStream fos = new FileOutputStream(summaryFile);
                    fos.getChannel().transferFrom(rbc, 0, Long.MAX_VALUE);
                }

                try (FileReader fileReader = new FileReader(summaryFile)) {
                    JSONObject jsonObject = (JSONObject) (new JSONParser().parse(fileReader));
                    for (Object value : jsonObject.values()) {
                        JSONObject item = (JSONObject) value;
                        if ((Boolean) item.get("tradeable_on_ge")){

                            allGEItems.put((Long) item.get("id"),new Item().setId((Long) item.get("id"))
                                    .setMembers((Boolean) item.get("members"))
                                    .setName((String) item.get("name"))
                            );

                        }
                    }

                }
            } catch (IOException | ParseException e) {
                e.printStackTrace();
            }
             summaryFile = Paths.get(System.getProperty("user.home"), "OSBot", "Data", "ge-limits-ids.json").toFile();
            try {
                if (!summaryFile.exists()) {
                    URL website = new URL("https://raw.githubusercontent.com/osrsbox/osrsbox-db/master/data/items/ge-limits-ids.json");
                    ReadableByteChannel rbc = Channels.newChannel(website.openStream());
                    FileOutputStream fos = new FileOutputStream(summaryFile);
                    fos.getChannel().transferFrom(rbc, 0, Long.MAX_VALUE);
                }
                try (FileReader fileReader = new FileReader(summaryFile)) {
                    JSONObject jsonObject = (JSONObject) (new JSONParser().parse(fileReader));
                    for (Object value : jsonObject.keySet()) {

                        if (allGEItems.containsKey(Long.valueOf((String) value) )){

                            System.out.println(jsonObject.get(value));

                            if (jsonObject.get(value)!=null){

                                allGEItems.get(Long.valueOf((String) value)).setBuyLimit((Long) jsonObject.get(value));

                            }else {
                                allGEItems.get(Long.valueOf((String) value)).setBuyLimit(-1);



                            }

                        }

                    }

                }
            } catch (IOException | ParseException e) {
                e.printStackTrace();
            }



        }
        allGEItems.values().forEach(s->GeItems.add(s.getItem()));
        Object[][] array2d = GeItems.toArray(new Object[GeItems.size()][]);
        return array2d;
    }


    public static Map<Long, Item> getGeItems() {
        if (allGEItems.isEmpty()){
            getAllGEItems();

        }
        return allGEItems;
    }
}

 

 

 

Id -> Image


   Image image =null;

    private void drawitem(){
        if (image ==null){

            URL url = null;

            try {
                url = new URL("https://rsbuddy.com/items/" + itemid+".png");
            } catch (MalformedURLException e) {
                e.printStackTrace();
            }

            try {
                image = ImageIO.read(url);

            } catch (IOException e) {
                e.printStackTrace();
            }

        }
        Graphics g = c.getGraphics();
        Graphics2D g2 = (Graphics2D) g;
        if (image!=null){

            g.drawImage(image, 55, 50,60,60,null );
            g.setColor(lowlites);
            g2.setStroke(new BasicStroke(3));

        }else {
            drawText("ERROR", 50 ,50,Color.white,font1);
        }
        
        g2.setStroke(new BasicStroke(1));
        g.setColor(Color.black);
        g2.draw(new RoundRectangle2D.Double(50, 50, 60, 60, 10, 10));

    }

 

 

So, you are getting item ID from osrsbox, item image from rsbuddy, if tradeable or not and G.E limits but where does the G.E price come from? Also, the item image is just the icon :( wanted to get a high quality one like this: https://oldschool.runescape.wiki/images/thumb/3/30/Abyssal_whip_detail.png/800px-Abyssal_whip_detail.png?70893

4 hours ago, Consulti said:

So, you are getting item ID from osrsbox, item image from rsbuddy, if tradeable or not and G.E limits but where does the G.E price come from? Also, the item image is just the icon :( wanted to get a high quality one like this: https://oldschool.runescape.wiki/images/thumb/3/30/Abyssal_whip_detail.png/800px-Abyssal_whip_detail.png?70893

I can count the amount of polygones of an rs item on 1 hand why do you need 80kb images? There is around 10k items and 4k tradeable items all of those with high qualty images is between 300mb - 800. That is alot. 

Get the prices like https://services.runescape.com/m=itemdb_oldschool/api/catalogue/detail.json?item=*ID*

  • Author
1 minute ago, Nbacon said:

I can count the amount of polygones of an rs item on 1 hand why do you need 80kb images? There is around 10k items and 4k tradeable items all of those with high qualty images is between 300mb - 800. That is alot. 

Get the prices like https://services.runescape.com/m=itemdb_oldschool/api/catalogue/detail.json?item=*ID*

We wanna animate the item like zoom in/out, check specific details but for that, the image needs to be big and in HD, the icon currently offered are too small for that. The file size is not a big deal since we won't load it all at once, just the 4k tradeable item and the user would have access 1 by 1.

Thanks for the price suggestion, is https://rsbuddy.com/exchange/summary.json still reliable?

  • Author
19 hours ago, Nbacon said:

*Zooms in* HMMMMM... Still a whip but bigger.

for prices no.

Yeah, but anyway, I guess there's no easy way for that currently. 

Regarding rsbuddy, I really thought they were the most reliable due to ge-tracker using their system? Thanks for letting me know.

Create an account or sign in to comment

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.