Marvel's Spider Man
releases on September 26, 2025!

Preorder now on CardKingdom Preorder now on TcgPlayer

Marvel's Spider Man
releases on September 26, 2025!

Preorder now on CardKingdom Preorder now on TcgPlayer
11 total results       Page 1 of 1
You must login or register to post a new reply
Posts [ 1 to 11 ]
Trade score 0 (100%)
Members
Registered: 13-Jan-2010 16:24
Posts: 14
30-Aug-2012 13:44 (Last edited: 30-Aug-2012 14:54)
1
Hi,

I was thinking of trying to make something similar to Cockatrice and Magic Workstation but that's fully web-based. The idea is that you can play is in your browser and by that also on iPad and other tablets, anything with a browser really. This is just an idea, and might never be realised, but I do it for fun and if it works out it might become something cool.
Now, I love DeckBox and it would be cool that people can just make their decks here, and then use them in my app. So my question is, are there any api's from deckbox for this kind of thing? Also for getting the card pictures by their name and stuff?
I couldn't find anything, so I thought to ask to be sure. It's going to be fully html/javascript.

Also, if there isn't something like this from Deckbox, I'll be sad, but it won't stop me. So if you know anything else, that would also be welcome! (I'll be looking for something too while you read this, though any suggestion is welcome.)

Thanks a lot!
-Pablo
Trade score 13 (100%)
Administrators
Registered: 18-May-2009 18:29
Posts: 3444
Hi Pablo,

We don't have an API yet but we'd like to make one in the future.

As for card images, you can already get them: http://deckbox.org/help/tooltips
Trade score 0 (100%)
Members
Registered: 13-Jan-2010 16:24
Posts: 14
sebi wrote:Hi Pablo,

We don't have an API yet but we'd like to make one in the future.

As for card images, you can already get them: http://deckbox.org/help/tooltips

Thanks,

Though is there any way to get the image, description, manacost, ... of a card from javascript by it's name?
Trade score 13 (100%)
Administrators
Registered: 18-May-2009 18:29
Posts: 3444
Sorry, I misread your post regarding the images. :)

The only thing you can easily fetch right now is a card's image, by using a url like this:

http://deckbox.org/mtg/Ponder/tooltip

(Where you replace Ponder by any mtg card name).
Trade score 0 (100%)
Members
Registered: 13-Jan-2010 16:24
Posts: 14
sebi wrote:Sorry, I misread your post regarding the images. :)

The only thing you can easily fetch right now is a card's image, by using a url like this:

http://deckbox.org/mtg/Ponder/tooltip

(Where you replace Ponder by any mtg card name).

That works great thanks! Was using a similar way but for the gatherer stuff. Now I just have to find the manacost & power somewhere :P
Thanks :D
Trade score 0 (100%)
Members
Registered: 13-Jan-2010 16:24
Posts: 14
I have one more question. I can get the images perfectly, and they show correctly too. Though I get a warning "Resource interpreted as Image but transferred with MIME type text/html".
As far as I could figure out, it's because the image isn't saved as an image, but as text (when you go to the image's url you also get text, and not an image). Though is there a way to tell the browser it's all OK, and he shouldn't be worried? :P
Also, why is it saved as text? Is this by design, and if so, why?

Thanks :D
Trade score 13 (100%)
Administrators
Registered: 18-May-2009 18:29
Posts: 3444
Yep, looks like the mime type is wrongly set on them. Should be fixed soon! Thanks for reporting.
Trade score 0 (100%)
Members
Registered: 13-Jan-2010 16:24
Posts: 14
sebi wrote:Yep, looks like the mime type is wrongly set on them. Should be fixed soon! Thanks for reporting.

No problem! Though I just tried again, and it's still text. Maybe you forgot about it? If not, it's not really a problem, though just though to remind you ^^

Thanks!
Trade score 0 (100%)
Members
Registered: 05-Dec-2012 14:36
Posts: 1
I would also like to have an API to this information. Here's to hoping this is in the works!! :)
Trade score 0 (100%)
Members
Registered: 13-Jan-2010 16:24
Posts: 14
Hi,

I've been doing some more investigating (and someone on Stackoverflow helped me), and in my program the problem isn't that the mime type is wrong (though it still is) it's that the url for the image doesn't end on an image extension (jpg, png, ...)
Still, a proper API would be super awesome :D Any nearer to getting this? :P

Thanks!
Trade score 0 (100%)
Members
Registered: 13-Jan-2010 16:24
Posts: 14
22-Jan-2013 22:28 (Last edited: 24-Jan-2013 13:51)
11
Hey,

I just noticed you updated it. I can now use "http://deckbox.org/mtg/Ponder/tooltip.jpg" and it works awesomely!
Thanks a lot for that!

Edit: It doesn't work anymore now :(
Edit2: It does work for some cards, just not all... Yesterday it worked for Ponder, now it doesn't. Though it does work for "Teroh's Faithful". (Those are the only two I tried.)
Posts [ 1 to 11 ]
11 total results       Page 1 of 1
You must login or register to post a new reply