DiFi, or deviantART Interactive Fragmented Interface, is an RPC/AJAX centric service used to populate pages and send data to and from the deviantART servers. Early research into DiFi and its capabilities was carried out by the dAmnHack team.
Each DiFi packet is broken down into sections, as the dAmnHack team found, these sections are as follows:
DiFi method call
There are two different formats for sending a DiFi call. One is as so:
The other one, which is used in newer code, is as so:
With this newer method, there's a shortcut for calling the same method with two different sets of arguments. For example:
...is equivalent to this:
argument1 .. argumentn are arguments to a DiFi method. As hinted above, you can set the c argument multiple times to do more than one DiFi call at once. The individual pieces of this call are the:
The DiFi classes are listed below.
See a class for methods.
See a class method for arguments.
This is set by using the t url variable
- json — This gives the data output in the JSON standard format.
- xml — This provides output as an XML document that can be parsed using any XML walker.
- php — This gives an output of a multi-dimensional PHP array, very useful in maybe a PHP bot.
- page — This provides an output of a deviantart.com page, with the data encoded into JSON as an object in the page.
- default — This gives an output in a human-readable, messy table format, not at all recommended for use other than testing.
Sometimes, in a call you must set an argument called ui, which appears to be your "userinfo" cookie. This is probably used to help prevent XSRF (Cross Site Request Forgery) as this has been a problem on deviantART in the past.
These are all of the currently known classes for DiFi: