"...the Confederate decision to intervene in Cuba added another wrinkle to a profoundly complicated war. Spain had reinforced her garrisons both in Cuba and in Santo Domino, where a longer but more subtle guerilla war had been smoldering since the mid-1860s upon the ascension of Leopold to the monarchy. With the new constitution passed, the Cortes in Madrid was debating how to apply the governing document to the colonies - a large bloc of the Democratic Liberals who held a majority supported incorporating the three Caribbean territories as full provinces of Spain with the same rights and privileges as any other Spanish province, thus removing the exploitative colonial relationship and simultaneously addressing many of the grievances of the Republic at Arms, as the "East Cuba" rebels under Cespedes, Agramonte and Gomez were called. A smaller bloc, led by President of the Cortes (Prime Minister) Juan Prim, were in favor of releasing Cuba and Santo Domingo completely, making Puerto Rico the last focal point of the Spanish New World colonial system and turning attention to reforms within the country. Arguments in Spain mirrored arguments within the East Cuba rebellion, where Cespedes and Agramonte frequently jockeyed for power against one another and supported full independence, whereas more pragmatically minded rebels such as the Maceo brothers were open to a provincial arrangement with most of their demands met as a way to end the bloodshed. Most notably, the Maceos - of mixed race - had effectively won on the issue most dear to them, the abolition of slavery, and were skeptical that an independent Cuba could successfully resist the intervention of the neighboring Confederacy which would surely install a puppet government that would reimpose slavery. Within Spain, freedom for all black and mulatto Cubans was effectively secure.
Spain had successfully used such wedges to defend its position and thus was caught off guard by the West Cuba government established by the Pinar del Rio and Matanzas sugar oligarchy, headed by Juan Salcedo [1], in late 1871 and its immediate recognition by the Confederacy. For a brief moment, it appeared that Prim's instincts on withdrawing from "the nest of vipers" and the now-multisided war in Cuba would win out. Spain had an ally, however, one that would be quite useful: the United States.
Officially, the United States took no position on the war in Cuba, considering it an internal matter of the Kingdom of Spain. Unofficially, the United States government had two positions: they were generally skeptical of if not opposed to Cuban independence due to concerns that the island would fall into the hands of another power, most worryingly Britain, France or the Confederacy (Spain was not a Great Power and American dealings with Madrid had always been courteous and, more importantly in a post-Havana world, predictable), but much of the public, thanks to newspapers and Cuban insurrectionists fundraising in New York, sympathized with the republican and abolitionist sentiments of the Cespedes-led Republic at Arms [2]. It made this confused neutrality much easier for Secretary of State Hamilton Fish when Spain abolished slavery, and he had offered to mediate an end to the war when the Salcedo regime was declared and then recognized by Richmond. To President Chase and his Cabinet, it was an echo of the Confederacy declaring what had then been an illegal secession, also over the matter of slavery, and then recognized by opportunistic foreign powers. "Spain is no suffering the same cruel betrayal of diplomatic etiquette we too were subjected to," Chase declared in his diary. Though the United States would never formally enter the war on Spain's side, the small-scale shipments of arms to both rebel and Spanish forces ceased and Spain became the sole beneficiary of American weapons, and volunteers, adventurers and mercenaries headed to the Caribbean to fight for the insurrection and earn a reward in the new Cuba were suddenly receiving funding from American bankers, possibly at the encouragement of Chase himself, to instead present their services to the Spanish Crown.
Other foreign powers had renewed interest in the events in Cuba, too. For Mexico's Maximilian, despite his lingering personal distaste for slavery in general and Nathan Bedford Forrest in particular, was quietly sympathetic towards the Confederate intervention in a hope that it would result in at the very least an independent Cuba that Mexico could help influence. In France, where Napoleon III was in his last years of life and the government was run by a reactionary cabal known as "Le Trois" [3], there was hope for another state within the French sphere and that a loss in Cuba would eventually mean a Spanish withdrawal from Santo Domingo, allowing the Second Empire to fulfill its long-term ambitions to vassalize the entire island of Hispaniola again. There was also opposition to the liberal Spanish state generally and the Hohenzollern King specifically within France [4], which viewed it as a German encirclement and which was host to the exiled Bourbon dynasty overthrown in 1868. Germany, for its part, secured commitments from Spain as to German settlers in Cuba, many of whom had formed volunteer militias to defend their property, and dispatched military advisors to assist in the war effort out of hopes for economic opportunities in the Caribbean that would come with a Spanish victory. And finally, Britain, courteous with Spain and with its own investments in the New World to concern itself with, was leery of the Confederacy enjoying de facto control over both sides of the Florida Straits with which it could control the quickest route of access to Mexico and the Tehuantepec Isthmus specifically [5] (Britain, it should be noted, had several years since surpassed France as Maximilian of Mexico's primary financial benefactor and the largest investor in the country)…"
- The Cuban Revolt at 100
[1] Fictional person
[2] This was effectively the US position during OTL Ten Years War - supportive of Spain generally and quietly opposed to Cuban independence, but turned a blind eye to domestic support/fundraising for the rebels. Here, with a Confederacy that at minimum wants to vassalize Cuba if not outright annex it depending on circumstances (recall there's a constellation of opinions within Forrest's Cabinet and his main goal is just war glory for its own sake in the short term), their support for Spain is considerably more overt
[3] Style note - Since different "textbooks" provide Cinco de Mayo's excerpts, Le Trois would not have been mentioned previously in this one.
[4] More on this later
[5] See also: British stance on one country controlling both sides of the Straits of Gibraltar or the Straits of Tunis