BGP internal vs external

By definition, peerings between BGP routers on the same AS are considered iBGP. Similarly, by definition, peerings between BGP routers on different ASes are considered eBGP.

iBGP is responsible for advertising networks to other BGP routers within an AS. This includes BGP routers that may be on the edge of the AS and may have connections to other ASes.

These edge BGP routers will use eBGP to create peerings with routers on other ASes. All internal networks that have been learned via iBGP can then be shared between ASes over such eBGP peerings. Thus, eBGP routers are responsible for advertising their internal networks learned via iBGP to other eBGP routers in other ASes.

https://networklessons.com/bgp/how-to-configure-ebgp-external-bgp https://networklessons.com/bgp/internal-bgp-border-gateway-protocol-explained