Various versions of DirectX are available on both Windows and Xbox. Are the libraries the same on both platforms? Obviosly I'm talking about the interfaces — such as the ones for working with windows, input, etc —, not their actual implementation.
The APIs available on Windows and the 360 are similar, but they are not the same. It's not really possible to provide more details without running afoul of NDAs, really.
However, you could look at the difference between how XNA operates on Windows and on the 360 for some vague, rough ideas of about the class of differences you may expect to see, at least in terms of how behavior and functionality can differ even though the API remains the same.