From H. W. Smyth, Greek Grammar, I §§149-188
GENERAL PRINCIPLES, ANASTROPHE, CHANGE OF ACCENT IN DECLENSION, INFLECTION AND COMPOSITION, PROCLITICS, ENCLITICS
175. Anastrophe (ἀναστροφή turning-back) occurs in the case of oxytone prepositions of two syllables, which throw the accent back on the first syllable.
a. When the preposition follows its case: τούτων πἐρι (for περὶ τούτων) about these things. No other preposition than περί follows its case in prose.
N. 1.– In poetry anastrophe occurs with the other dissyllabic prepositions (except ἀντί, ἀμφί, διά). In Homer a preposition following its verb and separated from it by tmesis also admits anastrophe (λούσῃ ἄπο for ἀπολούσῃ).
N. 2.– When the final vowel of the preposition is elided, the accent is dropped if no mark of punctuation intervenes: χερσὶν ὑφ' ἡμετέρῃσιν.
b. When a preposition stands for a compound formed of the preposition and ἐστί. Thus, πάρα for πάρεστι it is permitted, ἔνι for ἔνεστι it is possible (ἐνί is a poetic form of ἐν).
N. – In poetry, πάρα may stand for πάρεισι or πάρειμι; and ἄνα arise! up! is used for ἀνάστηθι. Hom. has ἔνι = ἔνεισι.
Reference address : https://www.ellopos.net/elpenor/lessons/greek-accentuation.asp?pg=7