Fantasy world economics 101: Introduction

I got to thinking about economics in a Fantasy world, particularly my RPG world, after someone posed the question of why there would be beggars in a Dungeons and Dragons game.

The basic answer is because that’s the best way they have of making a living.

But why would that be anyone’s best choice?

Anyone with a crippling injury can be healed by magic. But if magic is rare and expensive, many people won’t be.

In a world where 90% or more of all tasks have to be done by muscle power, someone who lacks muscle power won’t be able to do useful work. Technology isn’t around to ease burdens, and while magic can take the place of technology, how prevalent is durable magic in the world?