What kind of restrictions? So what is the process in 10 days?
I can get around, but have to social distance and wear a P2 (N95) mask outside my room. The hotel will not clean (or enter) my room until I am negative. I get room service food delivered to my room, and wait until they leave to open the door and get the food. If I walk to a local restaurant, I have to get takeout. Spain doesn’t require you to quarantine, but they are pretty serious about the other requirements. Thy are available online.
To board a plane for the United States, I have two options: a negative COVID test, or a certificate of recovery which means it has been ten full days since the positive test. After 10 days you can still test positive (something that can happen for months after you are infected), but you are considered to not be a risk to others anymore.
There are a number of local clinics that will produce the certificate for you; they will even come to where you are with their mobile lab. All you will need is your positive test result, your passport or other document, and (from what I can tell) about €80. There are also a number of other online options.
In my preparation for the Camino I decided to bring along a couple of boxes of test kits the Post Office was giving out; I’m glad I did. The repeated tests are expensive. I can test myself and only pay for one more official test after I know I am negative.