Cities are rapidly becoming composed of digitally-mediated components and infrastructures, their systems augmented and mediated by software, with widespread consequences for how they are managed, governed and experienced. This transformation has been accompanied by critical scholarship that has sought to understand the relationship between code and the city. Whilst this work has produced many useful insights, in this paper I argue that it also has a number of shortcomings. Principal amongst these is that the literatures concerning code and the city have remained quite divided. Studies that focus on code are often narrow in remit, fading out the city, and tend to fetishize and potentially decontextualises code at the expense of the wider socio-technical assemblage within which it is embedded. Studies that focus on the city tend to examine the effects of code, but rarely unpack the constitution and mechanics of the code producing those effects. To provide a more holistic account of the relationship between code and the city I forward two interlinked conceptual frameworks. The first places code within a wider socio-technical assemblage. The second conceives the city as being composed of millions of such assemblages. In so doing, the latter seeks to provide a means of productively building a conceptual and empirical understanding of programmable urbanism that scales from individual lines of code to the complexity of an entire urban system.