How to use other properties in hook_entity_property_info_alter()
If you use hook_entity_property_info_alter() you have access to the entity in question in the callback as well.

function mymodule_callback($item){
  //$item is the entity in question in my case $og_membership
  //hence I can acces the gid like this:
  $og_membership = $item; //redundant, just to show what I mean
  $gid = $og_membership-&gt;gid;

  //either do some more stuff or just return the gid as an example
  return $gid;
}


Now I can access the property and it returns the gid. For example in rules:

[og_membership:og_custom_property]


Hope this is useful to others as well.