As mentioned in comments, the Vice President was originally the runner-up in the Presidential Election; this practically guaranteed that (until this was changed) the Vice President would be of a different party than the President.

Now, because the Vice President is on the ticket alongside the President, they will almost certainly be of the same party, but nothing besides politics would prevent a joint ticket across parties. [Bernie Sanders](https://en.wikipedia.org/wiki/Bernie_Sanders) has not advanced to be the Democratic Party's nominee though he has run for it, but it's worth noting that he isn't actually a member of the Democratic Party, he's an independent. Were he to have won the nomination it seems likely he would have chosen a Democrat to be his Vice President.

As for other political appointees, [Wikipedia has a helpful list](https://en.wikipedia.org/wiki/List_of_United_States_political_appointments_across_party_lines). [Walter Gresham](https://en.wikipedia.org/wiki/Walter_Q._Gresham), a Republican, served as Secretary of State for Grover Cleveland, a Democrat. Thomas Jefferson was also generally a political opponent of George Washington but served as Secretary of State prior to the development of the formal party system.

Many other appointments, even in recent times, have crossed party lines. Two different Republicans had time as Secretary of Defense while Barack Obama was president (Robert Gates stayed on from the same role in the Bush administration).

Appointments across part lines often involve people who are near the political center and/or have a long history of service in government itself rather than politics, such that their role is not as partisan. Others may be in their positions as part of a deal with an opposing party who controls the Senate confirmation process under the [Appointments Clause](https://en.wikipedia.org/wiki/Appointments_Clause), or in a more general demonstration of bipartisanship.