In Java, what exactly is an API? I have searched/read using google, and from what i understand it is "a set of classes and methods" and used specific documentation/commenting guidelines. But I still dont understand exactly what that means in terms of me creating an API. What makes my program different from an API besides for the documentation?
An API is basically an interface to a library of routines. It's a way to expose the functionality of one's code to others. Does your program serve some generically useful purpose that others would want to plug into (to reuse your code)? If not, then there's no reason to produce an API for it.
Think of it like this. If you were coding a program for a car you might have a class called 'car'. You might also have various types of cars pre-coded - honda, toyato, porche. And the methods for the car - drive, accellerate, reverse, brake, crash. You might then make an API to allow external users use those classes and methods. That is your API! You might also provide some documentation like JAVA does with seperate explanations for constructors for the car, classes and methods belonging to the Car. A basic example I know, but the thinking is much the same.