Question: when did dominican republic gain independence from spain
Answer: Previously known as the Captaincy General of Santo Domingo , the criollo class within the country overthrew the Spanish crown in 1821 before unifying with Haiti a year later .