An electronic device, comprising: a housing; a first near-distance wireless communication circuit; a second near-distance wireless communication circuit configured to provide a wireless coverage broader than the first near-distance wireless communication circuit, and support wireless connection to an access point, AP; a cellular wireless communication circuit; a touchscreen display exposed through a portion of the housing; a processor positioned in the housing and connected to the first near-distance wireless communication circuit, the second near-distance wireless communication circuit, the cellular wireless communication circuit, and the touchscreen display; and a memory positioned in the housing and operatively connected to the processor, wherein the memory is configured to store an application program configured to make payment using the first near-distance wireless communication circuit, and instructions, and wherein the instructions, when executed, cause the processor to: perform a transaction with an external point-of-service, POS, device via the first near-distance wireless communication circuit using the application program; receive a result of the transaction comprising receipt information and connection information from an external server via the cellular wireless communication circuit using the application program, wherein the connection information comprises credential information for connecting to the AP, wherein the credential information further comprises period information for connection to the AP; and connect to the AP through the second near-distance wireless communication circuit based on the credential information after receiving the result of the transaction, wherein the instructions, when executed, further cause the processor to, when performing the transaction operate a timer based on the period information; and terminate connection to the AP when the timer expires. a housing; a first near-distance wireless communication circuit; a second near-distance wireless communication circuit configured to provide a wireless coverage broader than the first near-distance wireless communication circuit, and support wireless connection to an access point, AP; a cellular wireless communication circuit; a touchscreen display exposed through a portion of the housing; a processor positioned in the housing and connected to the first near-distance wireless communication circuit, the second near-distance wireless communication circuit, the cellular wireless communication circuit, and the touchscreen display; and a memory positioned in the housing and operatively connected to the processor, wherein the memory is configured to store an application program configured to make payment using the first near-distance wireless communication circuit, and instructions, and wherein the instructions, when executed, cause the processor to: perform a transaction with an external point-of-service, POS, device via the first near-distance wireless communication circuit using the application program; receive a result of the transaction comprising receipt information and connection information from an external server via the cellular wireless communication circuit using the application program, wherein the connection information comprises credential information for connecting to the AP, wherein the credential information further comprises period information for connection to the AP; and connect to the AP through the second near-distance wireless communication circuit based on the credential information after receiving the result of the transaction, wherein the instructions, when executed, further cause the processor to, when performing the transaction operate a timer based on the period information; and terminate connection to the AP when the timer expires. perform a transaction with an external point-of-service, POS, device via the first near-distance wireless communication circuit using the application program; receive a result of the transaction comprising receipt information and connection information from an external server via the cellular wireless communication circuit using the application program, wherein the connection information comprises credential information for connecting to the AP, wherein the credential information further comprises period information for connection to the AP; and connect to the AP through the second near-distance wireless communication circuit based on the credential information after receiving the result of the transaction, wherein the instructions, when executed, further cause the processor to, when performing the transaction operate a timer based on the period information; and terminate connection to the AP when the timer expires. operate a timer based on the period information; and terminate connection to the AP when the timer expires.